Description Usage Arguments Value Examples
View important terms as a comma separated string (a topic).
1 2 3 4 |
x |
A |
max.n |
The max number of words to show before truncation. |
sort |
logical. If |
... |
ignored. |
Returns a data.frame
of "cluster"
,
"count"
, and "terms"
. Pretty prints as clusters, number of
documents, and associated important terms.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | library(dplyr)
myfit5 <- presidential_debates_2012 %>%
mutate(tot = gsub("\\..+$", "", tot)) %>%
textshape::combine() %>%
filter(person %in% c("ROMNEY", "OBAMA")) %>%
with(data_store(dialogue, stopwords = tm::stopwords("english"), min.char = 3)) %>%
hierarchical_cluster()
ca5 <- assign_cluster(myfit5, k = 50)
get_terms(ca5, .4) %>%
as_topic()
get_terms(ca5, .4) %>%
as_topic(sort=FALSE)
get_terms(ca5, .95) %>%
as_topic()
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.