Closed twolodzko closed 7 years ago
For very small values of prob parameter, rmnom returns NaNs, e.g.
prob
rmnom
NaN
p <- c(0, 0, 1, 0, 2.77053929981958e-18) rmnom(1, 100, p) ## [,1] [,2] [,3] [,4] [,5] ## [1,] 0 0 100 NaN NaN
Same with rdirmnom:
rdirmnom
rdirmnom(1, 100, p+1e-5) ## [,1] [,2] [,3] [,4] [,5] ## [1,] 0 0 100 NaN NaN
For very small values of
prob
parameter,rmnom
returnsNaN
s, e.g.Same with
rdirmnom
: