getTopics | R Documentation |
Returns the corresponding element of a LDA
object.
getEstimators
computes the estimators for phi
and theta
.
getTopics(x) getAssignments(x) getDocument_sums(x) getDocument_expects(x) getLog.likelihoods(x) getParam(x) getK(x) getAlpha(x) getEta(x) getNum.iterations(x) getEstimators(x)
x |
[ |
The estimators for phi
and theta
in
w_n^{(m)} \mid T_n^{(m)}, \bmφ_k \sim \textsf{Discrete}(\bmφ_k),
\bmφ_k \sim \textsf{Dirichlet}(η),
T_n^{(m)} \mid \bmθ_m \sim \textsf{Discrete}(\bmθ_m),
\bmθ_m \sim \textsf{Dirichlet}(α)
are calculated referring to Griffiths and Steyvers (2004) by
\hat{φ}_{k, v} = \frac{n_k^{(v)} + η}{n_k + V η},
\hat{θ}_{m, k} = \frac{n_k^{(m)} + α}{N^{(m)} + K α}
with V is the vocabulary size, K is the number of modeled topics; n_k^{(v)} is the count of assignments of the v-th word to the k-th topic. Analogously, n_k^{(m)} is the count of assignments of the m-th text to the k-th topic. N^{(m)} is the total number of assigned tokens in text m and n_k the total number of assigned tokens to topic k.
Griffiths, Thomas L. and Mark Steyvers (2004). "Finding scientific topics". In: Proceedings of the National Academy of Sciences 101 (suppl 1), pp.5228–5235, doi: 10.1073/pnas.0307752101.
Other getter functions:
getJob()
,
getSCLOP()
,
getSimilarity()
Other LDA functions:
LDABatch()
,
LDARep()
,
LDA()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.