Description Usage Arguments Details Value Author(s) References See Also Examples
The function implements the MCMC algorithm with data augmentation to estimate the parameters in the zero-inflated Poisson model. The function returns the trace of the sampled parameters in each interaction. To obtain the summary estimation, use summary
().
1 2 3 4 5 | ZIP(Y, Covarmainphi, Covarmainmu,
betaphi, betamu,
priorgamma,
propsigmaphi, propsigmamu = propsigmaphi,
seed = 1, nmcmc = 500)
|
Y |
a count vector of length n specifying response in the zero-inflated Poisson model. |
Covarmainphi |
a n \times p_1 dimensional data.frame or matrix of data with respect to the probability component of the zero-inflated Poisson model. |
Covarmainmu |
a n \times p_2 dimensional data.frame or matrix of data with respect to the mean component of the zero-inflated Poisson model. |
betaphi |
a vector of length p_1 specifying the initial values of the parameters in the probability component of the zero-inflated Poisson model |
betamu |
a vector of length p_2 specifying the initial values of the parameters in the probability component of the zero-inflated Poisson model |
priorgamma |
a vector of length 2 specifying the two parameters of gamma prior |
propsigmaphi |
a vector of length p_1 specifying the standard error of the Gaussian proposal distribution for the parameters corresponds to the probability component. |
propsigmamu |
a vector of length p_2 specifying the standard error of the Gaussian proposal distribution for the parameters corresponds to the mean component. |
seed |
a numeric value specifying the seed for random generator |
nmcmc |
a integer specify the number of the generation of MCMC algorithm |
The zero-inflated Poisson model involves two components, the probability components and the mean compoenents (Zhang, 2020). Argument Covarmainphi
, betaphi
, propsigmaphi
correspond to the probability compoenent; Covarmainmu
, betamu
, propsigmamu
correspond to the mean compoenent.
BayesResults |
the list of trace of generated parameters for each component of the models. Data.frame "betaphi_trace" corresponds to the probability component of ZIP response model; "betamu_trace" refers to the mean component of the ZIP response model. |
Qihuang Zhang and Grace Y. Yi
Zhang, Qihuang. "Inference Methods for Noisy Correlated Responses with Measurement Error." (2020).
1 2 3 4 5 6 7 8 9 10 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.