rdirichlet            package:LearnBayes            R Documentation

_R_a_n_d_o_m _d_r_a_w_s _f_r_o_m _a _D_i_r_i_c_h_l_e_t _d_i_s_t_r_i_b_u_t_i_o_n

_D_e_s_c_r_i_p_t_i_o_n:

     Simulates a sample from a Dirichlet distribution

_U_s_a_g_e:

     rdirichlet(n,par)

_A_r_g_u_m_e_n_t_s:

       n: number of simulations required

     par: vector of parameters of the Dirichlet distribution

_V_a_l_u_e:

     matrix of simulated draws where each row corresponds to a single
     draw

_A_u_t_h_o_r(_s):

     Jim Albert

_E_x_a_m_p_l_e_s:

     par=c(2,5,4,10)
     n=10
     rdirichlet(n,par)

