powered by
Draw from Dirichlet distribution
rdirichlet(n, gam)
number of variates to draw
a vector of concentration parameters of length K
K
matrix dimension n*k of samples
n*k
# NOT RUN { rdirichlet(1, rep(2,5)) ## a length-5 probability vector # }
Run the code above in your browser using DataLab