| draw_classes | R Documentation |
Draw latent class memberships from their marginal distribution
draw_classes(n, pi_)
n |
Integer. Sample size. |
pi_ |
Numeric vector of length T. Class proportions (must sum to 1). |
Integer vector of length n with values in 1:T.
# Draw 100 class labels from equal prevalences
draw_classes(100, c(1/3, 1/3, 1/3))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.