term

Purpose

The function term() is used to search for items from a given list of words (a word class).

Syntax

term([part_of_speech,] word_class_name, …​)

Arguments

The function requires a word class name and takes any number of list names from a dictionary of the WordClasses category.

To narrow the search it is possible to state an optional argument part of speech (POS-tag). In such case the function will only return those word class matches that have the indicated POS-tag.

The function also supports optional named parameters as follows:

  • stem:=yes/no: matches any stem of words in wordlist/match only exact forms in the wordlist;

  • pos:=yes/no: matches only if the part of speech matches one of the parts of speech indicated for the word in the wordlist/match independent of part of speech;

  • allow_punct:=yes/no allows or prohibits punctuation between arguments (set to "yes" by default);

  • allow_space:=yes/no allows or prohibits spaces between arguments (set to "yes" by default);

  • match:=range extracts the whole fragment of text between the first and the last argument, including punctuation.

Returned Value

Documents matching the query.

Examples

term(noun, months) returns all word forms of elements from the Months word class if they are nouns, e.g. "November", "November’s", "Novembers", "December".