You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Texthero's hero.term_frequency(s) should be reanamed hero.count(s) as in reality it just count the term.
Because of that, we should add another function that implements hero.term_frequency that is: "(number of times term t appears in a document) / (Total number of terms in the document).
The distinctions between the two should be made clear in both docstring and both functions should have a "See Also" to let the user quickly move from one function documentation to the other.
Both implementations might be written using scikit-learn CountVectorizer.
The text was updated successfully, but these errors were encountered:
If I understand correctly, the existing term_frequency method has to be renamed to count without any modification except that in the docstring, and another term_frequency method needs to be defined?
Texthero's
hero.term_frequency(s)
should be reanamedhero.count(s)
as in reality it just count the term.Because of that, we should add another function that implements
hero.term_frequency
that is: "(number of times term t appears in a document) / (Total number of terms in the document).The distinctions between the two should be made clear in both docstring and both functions should have a "See Also" to let the user quickly move from one function documentation to the other.
Both implementations might be written using scikit-learn CountVectorizer.
The text was updated successfully, but these errors were encountered: