[R] Alternative function for Dictionary ( )
Patrick.Casimir at moffitt.org
Tue May 16 15:19:15 CEST 2017
Since the Dictionary () function is no longer available with the tm package. How do I use other functions to do the same as below? I want to capture a list of specific terms from a corpus. By example, if my corpus has 100 files. I want to see a list with
occurrences of price, crude, oil in all 100 files.
d <- Dictionary(c("prices", "crude", "oil"))
inspect(DocumentTermMatrix(reuters, list(dictionary = d)))
Please consider the environment before printing this email.
This transmission may be confidential or protected from disclosure and is only for review and use by the intended recipient. Access by anyone else is unauthorized. Any unauthorized reader is hereby notified that any review, use, dissemination, disclosure or copying of this information, or any act or omission taken in reliance on it, is prohibited and may be unlawful. If you received this transmission in error, please notify the sender immediately. Thank you.
[[alternative HTML version deleted]]
More information about the R-help