DirMnom | R Documentation |
Density function, cumulative distribution function and random generation for the Dirichlet-multinomial (multivariate Polya) distribution.
ddirmnom(x, size, alpha, log = FALSE)
rdirmnom(n, size, alpha)
x |
|
size |
numeric vector; number of trials (zero or more). |
alpha |
|
log |
logical; if TRUE, probabilities p are given as log(p). |
n |
number of observations. If |
If (p_1,\dots,p_k) \sim \mathrm{Dirichlet}(\alpha_1,\dots,\alpha_k)
and
(x_1,\dots,x_k) \sim \mathrm{Multinomial}(n, p_1,\dots,p_k)
, then
(x_1,\dots,x_k) \sim \mathrm{DirichletMultinomial(n, \alpha_1,\dots,\alpha_k)}
.
Probability density function
f(x) = \frac{\left(n!\right)\Gamma\left(\sum \alpha_k\right)}{\Gamma\left(n+\sum \alpha_k\right)}\prod_{k=1}^K\frac{\Gamma(x_{k}+\alpha_{k})}{\left(x_{k}!\right)\Gamma(\alpha_{k})}
Gentle, J.E. (2006). Random number generation and Monte Carlo methods. Springer.
Kvam, P. and Day, D. (2001) The multivariate Polya distribution in combat modeling. Naval Research Logistics, 48, 1-17.
Dirichlet
, Multinomial
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.