mallet_model | R Documentation |
A topic model is a complicated beastie, and exploring it requires keeping
track of a number of different kinds of data. The mallet_model
object
strives to encapsulate some of this for you. Package users shouldn't need to
invoke the constructor explicitly; to obtain model objects, use either
train_model
or load_mallet_model
. The
summary
method indicates which elements of the model have been loaded
into R's memory.
mallet_model( doc_topics = NULL, doc_ids = NULL, vocab = NULL, top_words = NULL, topic_words = NULL, params = NULL, hyper = NULL, metadata = NULL, model = NULL, ss = NULL, instances = NULL ) ## S3 method for class 'mallet_model' print(x) ## S3 method for class 'mallet_model' summary(x) ## S3 method for class 'mallet_model_summary' print(x)
doc_topics |
document-topic matrix |
doc_ids |
vector of document ids corresponding to rows of
|
vocab |
vector of word types corresponding to columns of
|
top_words |
data frame with top-ranked words and their weights for each topic |
topic_words |
topic-word matrix (expected to be sparse) |
params |
list of modeling parameters |
hyper |
list of estimated hyperparameters α and β |
metadata |
data frame of metadata |
model |
reference to an RTopicModel object from MALLET |
ss |
final Gibbs sampling state represented as "simplified"
|
instances |
reference to InstanceList (redundant if |
Any of the parameters to the constructor can be omitted. No validation is performed.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.