makeWordlist {tosca} | R Documentation |
Counts Words in Text Corpora
Description
Creates a wordlist and a frequency table.
Usage
makeWordlist(text, k = 100000L, ...)
Arguments
text |
List of texts. |
k |
Integer: How many texts should be processed at once (RAM usage)? |
... |
further arguments for the sort function. Often you
want to set |
Details
This function helps, if table(x)
needs too much RAM.
Value
words |
An alphabetical list of the words in the corpus |
wordtable |
A frequency table of the words in the corpus |
Examples
texts <- list(A="Give a Man a Fish, and You Feed Him for a Day.
Teach a Man To Fish, and You Feed Him for a Lifetime",
B="So Long, and Thanks for All the Fish",
C="A very able manipulative mathematician, Fisher enjoys a real mastery
in evaluating complicated multiple integrals.")
texts <- cleanTexts(text=texts)
makeWordlist(text=texts, k = 2L)
[Package tosca version 0.3-2 Index]