View source: R/text_analysis_patrick.R
preprocess_ngrams | R Documentation |
Preprocess a text corpus including the creation of n-grams and return a document feature matrix (wrapper round quanteda functions).
preprocess_ngrams( the_corpus, n, min_termfreq = 2, min_docfreq = 2, max_termfreq = NULL, max_docfreq = NULL, remove_punct = TRUE, remove_numbers = TRUE, remove_hyphens = TRUE, termfreq_type = "count", docfreq_type = "count", dfm_tfidf = FALSE )
the_corpus |
The text corpus to be pre-processed. |
n |
Upper-bound of n-grams to be included. E.g., entering 2 would mean that uni-grams and bi-grams are included |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.