rdirichlet {LearnBayes} | R Documentation |
Random draws from a Dirichlet distribution
Description
Simulates a sample from a Dirichlet distribution
Usage
rdirichlet(n,par)
Arguments
n |
number of simulations required |
par |
vector of parameters of the Dirichlet distribution |
Value
matrix of simulated draws where each row corresponds to a single draw
Author(s)
Jim Albert
Examples
par=c(2,5,4,10)
n=10
rdirichlet(n,par)
[Package LearnBayes version 2.15.1 Index]