Description Usage Arguments Examples
Highlight the vocabulary indicative of the top terms (number specified by
no_topics
) for the top topics (number specified by
no_topics
present in a partition
.
1 2 3 4 | get_highlight_list(.Object, partition_obj, no_topics = 3L, no_token = 20L)
## S4 method for signature 'TopicModel'
read(.Object, partition_obj, no_topics = 3L, no_token = 20L)
|
.Object |
Object of class |
partition_obj |
A |
no_topics |
The number of the most prevalant topics in a text that will be highlighted. |
no_token |
An |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | data(BE_lda)
data(BE_labels)
data(BE_exclude)
BE <- Topicanalysis$new(topicmodel = BE_lda)
BE$labels <- BE_labels
BE$type <- "plpr_partition"
topic_flucht <- 125L
topic_integration <- 241
BE$docs(x = 125L, y = 241L)
# As sample data, we use a corpus of plenary debates in the
# 'Berliner Abgeordnetenhaus'. It is somewhat big and not included
# in the package by default.
## Not run:
polmineR::use("topicanalysis")
if (!"BE" %in% corpus()$corpus){
cwbtools::corpus_install(
pkg = "topicanalysis",
tarball = "http://polmine.sowi.uni-due.de/corpora/cwb/berlin/be.tar.gz"
)
polmineR::use("topicanalysis") # to activate corpus 'BE'
}
p <- partition("BE", date = "2005-04-28", who = "Körting")
p <- polmineR::as.speeches(p, s_attribute_name = "who")[[4]]
read(BE_lda, p, no_token = 150)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.