bags_to_tfidf | R Documentation |
Computes a TF-IDF weight vectors for a set of word bags.
bags_to_tfidf(data)
data |
the list containing the input word bags. |
Senin Pavel and Malinchik Sergey, SAX-VSM: Interpretable Time Series Classification Using SAX and Vector Space Model. Data Mining (ICDM), 2013 IEEE 13th International Conference on, pp.1175,1180, 7-10 Dec. 2013.
Salton, G., Wong, A., Yang., C., A vector space model for automatic indexing. Commun. ACM 18, 11, 613-620, 1975.
bag1 = data.frame( "words" = c("this", "is", "a", "sample"), "counts" = c(1, 1, 2, 1), stringsAsFactors = FALSE ) bag2 = data.frame( "words" = c("this", "is", "another", "example"), "counts" = c(1, 1, 2, 3), stringsAsFactors = FALSE ) ll = list("bag1" = bag1, "bag2" = bag2) tfidf = bags_to_tfidf(ll)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.