The number.ordinal() command returns the ordinal of the given number, 100 yields 100th, 3 yields 3rd and twenty-one yields twenty-first: print en. is_connective ( "but" )> True Converting between numbers and words and words like I, the, own, him which have little semantical value): print en. The is_connective() command returns True if the word is a connective (nevertheless, whatever, secondly. The is_persuasive() command returns True if the given word is a "magic" word (you, money, save, new, results, health, easy. The is_basic_emotion() command returns True if the given word expresses a basic emotion (anger, disgust, fear, joy, sadness, surprise): print en. Categorise words as emotional, persuasive or connective The is_html_tag() command returns True when the string is a HTML tag. The is_tag() command returns True when the given string is a tag, for example HTML or XML. You can also check for is_verb(), is_adjective() and is_adverb(): print en. The is_noun() command returns True when the given string is a noun. The is_number() command returns True when the given value is a number: import en Categorise words as nouns, verbs, numbers and more It takes some time to load all the data the first time. You can also put it in ~/Library/Application Support/NodeBox/. Put the en library folder in the same folder as your script so NodeBox can find the library.
0 Comments
Leave a Reply. |