rdirichlet {LearnBayes} | R Documentation |
Simulates a sample from a Dirichlet distribution
rdirichlet(n,par)
n |
number of simulations required |
par |
vector of parameters of the Dirichlet distribution |
matrix of simulated draws where each row corresponds to a single draw
Jim Albert
par=c(2,5,4,10)
n=10
rdirichlet(n,par)