ZIPGUI: Bayes estimation of a zero inflated Poisson (ZIP) model

Description Usage Arguments Value Note References See Also Examples

Description

This function provides a GUI for the function rrisk.BayesZIP.

Usage

1
2
ZIPGUI(data=NULL, prior.lambda=c(1,10), prior.pi=c(0.8,1),
 chains=3, burn=1000, update=10000, thin=1)

Arguments

data

A vector of numeric data, containing zeros, and of minimal length 10.

prior.lambda

Numeric vector containing minimum and maximum of a uniform distribution used as prior for the Poisson parameter lambda, e.g.,
lambda ~ prior.lambda(*,*)=unif(*,*).

prior.pi

Numeric vector containing parameters of a beta distribution describing prior knowledge about prevalence (proportion of contaminated samples), e.g.,
pi ~ prior.pi(*,*)=beta(*,*).

chains

Positive single numeric value, number of independent MCMC chains (default 3).

burn

Positive single numeric value, length of the burn-in period (default 1000).

update

Positive single numeric value, length of update iterations for estimation (default 10000).

thin

Positive single numeric value (default 1). The samples from every kth iteration will be used for inference, where k is the value of thin. Setting thin > 1 can help to reduce the autocorrelation in the sample.

Value

The function ZIPGUI returns an instance of the bayesmodelClass class containing following information

convergence

Logical, whether the model has converged (assessed by the user).

results

Data frame containing statitsics of the posterior distribution.

jointpost

Data frame giving the joint posterior probability distribution.

nodes

Names of the parameters jointly estimated by the Bayes model.

model

Model in rjags/JAGS (originally BRugs/Winbugs) syntax as a character string.

chains

Number of independent MCMC chains.

burn

Length of burn-in period.

update

Length of update iterations for estimation.

Note

The convergence of the model will be entered by the user after the simulation process.

References

Bohning, D., E. Dietz, P. Schlattman, L. Mendonca, and U. Kirchner (1999). The zero-inflated Poisson model and the decayed, missing and filled teeth index in dental epidemiology. Journal of the Royal Statistical Society, Series A 162, 195-209.

See Also

rrisk.BayesZIP

Examples

1
2
data <- rpois(30, 4)
ZIPGUI(data)

BfRstats/rriskBayes2 documentation built on May 5, 2019, 2:42 p.m.