Description Usage Arguments Value References Examples
The function is sampling new word types based on posterior mode without hyper parameters.
This function is used for modeling comparisons using Bayesian checking. See reference for details.
1 | sample_tokens_given_topics(state, n = 1)
|
state |
a topic model state object |
n |
The number of random draws of tokens given topic. |
A tidy dataset with simulated tokens.
Mimno, D. and Blei, D. Bayesian Checking for Topic Models
1 2 3 | # Load the state of the union topic model
data("sotu50")
w <- sample_tokens_given_topics(state = sotu50, n = 5)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.