number of trials for each count to be generated in the sample, must be a vector of positive integers
a,b
vectors of shape parameters for beta distributions used to generate probability of success for each count to be generated in the sample, must be >0
checkArgs
single boolean specifying whether arguments should be checked for adherence to specifications. DEFAULT: FALSE
mu,rho
mean (a/(a+b)) and dispersion (1/(a+b+1)) parameters for beta distribution, must be in (0,1). Value of 0 is allowed for rho and implies binomial distribution.
Value
a numeric vector of betabinomial random variables.
Details
vectorizedRbetabinomAB is the same function as rbetabinom.ab from VGAM package but it avoids a lot of overhang and requires that arguments size, a (shape1), and b (shape2) be of length equal to argument n.
vectorizedRbetabinomMR is a wrapper around vectorizedRbetabinomAB using mu/rho parametrization. Requires that arguments size, mu, and rho be of length equal to argument n.