Description Usage Examples
Random draw for probability vector under sparse Dirichlet mixture model
1
rSDM(alpha, beta, logscale = FALSE, allout = FALSE)
1 2 3 4 5 6
K = 5 # number of categories a = rep(1.0, K) # Dirichlet shape parameter vector b = 10.0 # SDM parameter rSDM(a, b) # single draw from prior x = rbinom(K, 10, 0.3) # random count data rSDM(a+x, b) # single draw from posterior
Add the following code to your website.
REMOVE THIS Copy to clipboard
For more information on customizing the embed code, read Embedding Snippets.