MultiHypergeometric {extraDistr} | R Documentation |
Multivariate hypergeometric distribution
Description
Probability mass function and random generation for the multivariate hypergeometric distribution.
Usage
dmvhyper(x, n, k, log = FALSE)
rmvhyper(nn, n, k)
Arguments
x |
|
n |
|
k |
the number of balls drawn from the urn. |
log |
logical; if TRUE, probabilities p are given as log(p). |
nn |
number of observations. If |
Details
Probability mass function
The multivariate hypergeometric distribution is generalization of
hypergeometric distribution. It is used for sampling without replacement
out of
marbles in
colors, where each of the colors appears
times. Where
,
and
.
References
Gentle, J.E. (2006). Random number generation and Monte Carlo methods. Springer.
See Also
Examples
# Generating 10 random draws from multivariate hypergeometric
# distribution parametrized using a vector
rmvhyper(10, c(10, 12, 5, 8, 11), 33)
[Package extraDistr version 1.10.0 Index]