gd {hyperdirichlet} | R Documentation |
Specify a Dirichlet or generalized Dirichlet distribution as a special case of the hyperdirichlet distribution
dirichlet(params, powers) gd(a, b, b0 = 0, pnames = NULL)
params,powers |
Numeric vectors (supply exactly one) specifying the parameters or the powers respectively of the Dirichlet distribution |
a,b |
Numeric vectors of the same length specifying the parameters of the generalized Dirichlet distribution |
b0 |
Arbitrary constant for the generalized Dirichlet distribution |
pnames |
Character vector for name of the hyperdirichlet object |
Function dirichlet()
returns the hyperdicichlet distribution
corresponding to the classical Dirichlet distribution. If the vector
params|powers
is a named vector, then the hyperdirichlet object
inherits the names.
Function gd()
returns the hyperdicichlet distribution
corresponding to the generalized Dirichlet distribution of Connor and
Mosimann.
For convenience, the generalized Dirchlet distribution described here. Connor and Mosimann 1969 give the PDF as
ommitted...see a LaTeXed file
where p_1+...+p_k=1 and b_0 is arbitrary. If b_{i-1}=a_i+b_i for i=2,...,k-1 then the PDF reduces to a standard Dirichlet distribution with alpha_i=a_i for i=1,...,k-1 and alpha_k=b_{k-1}.
Wong 1998 gives the algebraically equivalent form
ommitted...see a LaTeXed file
for x_1+...+x_k <= 1 and x_j >= 0 for j=1,2,...,k and gamma_j=beta_j-beta_{j+1} for j=1,2,...,k-1 and gamma_k=beta_{k-1}.
Here, B(x,y)=G(x)G(y)/G(x+y) is the beta function.
These functions have cheaply evaluated analytic expressions for the normalizing constant
Robin K. S. Hankin
dirichlet(1:4) gd(1:5,5:1)