Package smile.nlp
Interface TextTerms
- All Known Implementing Classes:
SimpleText
public interface TextTerms
The terms in a text.
-
Method Summary
-
Method Details
-
size
int size()Returns the number of words.- Returns:
- the number of words.
-
words
Returns the iterator of the words of the document. The stop words and punctuations may be removed.- Returns:
- the iterator of the words of the document.
-
unique
Returns the iterator of unique words.- Returns:
- the iterator of unique words.
-
tf
Returns the term frequency.- Parameters:
term
- the term.- Returns:
- the term frequency.
-
maxtf
int maxtf()Returns the maximum term frequency over all terms in the document.- Returns:
- the maximum term frequency.
-