powered by
Generate a sample from a Dirichlet distirbution Using: https://en.wikipedia.org/wiki/Dirichlet_distribution#Random_number_generation
rdirichlet(n, alpha)
Number of observations.
A vector containing the parameters for the Dirichlet distribution.
A sample of n observations from the Dirichlet distribution.
# NOT RUN { rdirichlet(n=1, alpha=c(2, 2, 2)) # }
Run the code above in your browser using DataLab