dhyperBinMolenaar {DPQ} | R Documentation |
HyperGeometric (Point) Probabilities via Molenaar's Binomial Approximation
Description
Compute hypergeometric (point) probabilities via Molenaar's binomial
approximation, hyper2binomP()
.
Usage
dhyperBinMolenaar(x, m, n, k, log = FALSE)
Arguments
x |
(vector of) the number of white balls drawn without replacement from an urn which contains both black and white balls. |
m |
the number of white balls in the urn. |
n |
the number of black balls in the urn. |
k |
the number of balls drawn from the urn, hence in |
log |
|
Value
a numeric
vector, with the length the maximum of the
lengths of x, m, n, k
.
Author(s)
Martin Maechler
References
See those in phyperBinMolenaar
.
See Also
hyper2binomP()
;
R's own dhyper()
which uses more sophisticated
computations.
Examples
## The function is simply defined as
function (x, m, n, k, log = FALSE)
dbinom(x, size = k, prob = hyper2binomP(x, m, n, k), log = log)
[Package DPQ version 0.5-8 Index]