Description Usage Arguments Value References See Also
View source: R/maxcount_support.R
This function calculates the maximum support value for count variables by extending the method of Barbiero &
Ferrari (2015, doi: 10.1002/asmb.2072) to include regular and zero-inflated Poisson and Negative Binomial variables. In order for
count variables to be treated as ordinal in the calculation of the intermediate MVN correlation matrix, their infinite support must
be truncated (made finite). This is done by setting the total cumulative probability equal to 1 - a small user-specified value
(pois_eps
or nb_eps
). The maximum support value equals the inverse CDF applied to this result. The truncation values
may differ for each variable. The function is used in intercorr2
and corrvar2
and
would not ordinarily be called by the user.
1 2 3 |
k_pois |
the number of Poisson variables |
k_nb |
the number of Negative Binomial variables |
lam |
a vector of lambda (mean > 0) constants for the regular and zero-inflated Poisson variables (see |
p_zip |
a vector of probabilities of structural zeros (not including zeros from the Poisson distribution) for the
zero-inflated Poisson variables (see |
size |
a vector of size parameters for the Negative Binomial variables (see |
prob |
a vector of success probability parameters for the NB variables; order the same as in |
mu |
a vector of mean parameters for the NB variables (*Note: either |
p_zinb |
a vector of probabilities of structural zeros (not including zeros from the NB distribution) for the zero-inflated NB variables
(see |
pois_eps |
a vector of length |
nb_eps |
a vector of length |
a data.frame with k_pois + k_nb
rows; the column names are:
Distribution
Poisson or Negative Binomial
Number
the variable index
Max
the maximum support value
Barbiero A & Ferrari PA (2015). Simulation of correlated Poisson variables. Applied Stochastic Models in Business and Industry, 31:669-80. doi: 10.1002/asmb.2072.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.