Learn R Programming

eggCounts (version 0.4-1)

fec_mcmc: Modelling of Faecal Egg Count data (one-sample case)

Description

Modelling of Faecal Egg Count data in a one-sample case using either a Poisson gamma or a zero-inflated Poisson gamma model formulation.

Usage

fec_mcmc(fec, rawCounts = FALSE, f = 50, model = c("PoGa", "ZIPoGa")[1],
  priors.mu = list(hyperpars = c(1, 0.001), proposalDist = "kl"),
  priors.phi = list(hyperpars = c(1, 0.1), proposalDist = "unif", v = 0.5),
  priors.psi = list(hyperpars = c(1, 1)), maxiter.pilot = 10,
  nburnin = 1000, nsamples = 10000, thin = 1, initials = NULL,
  verbose = TRUE, .verboselevel = 0, ...)

Arguments

fec
vector with faecal egg counts
rawCounts
logical indicating whether fec corresponds to raw counts (as counted on the McMaster slide), or to calculated EpGs (raw counts times correction factor). Defaults to FALSE.
f
correction factor for the McMaster technique (e.g. 50). Either a number or a vector with different correction factors for each FEC
model
either "PoGa" or "ZIPoGa"
priors.mu
list with hyper-prior/proposal information for $\mu$
priors.phi
list with hyper-prior/proposal information for $\phi$
priors.psi
list with hyper-prior information for $\psi$
maxiter.pilot
maximal number of tries to determine a good tuning value for the proposal distribution for $\phi$
nburnin
number of burn-in iterations
nsamples
number of desired samples
thin
thinning parameter
initials
named list with starting values for the parameters mu, phi, mui, y,psi
verbose
print progress information
.verboselevel
print additional information, mainly for debugging information, larger values print more details
...
extra arguments (not used)

Value

  • a named list with
  • sampleslist with samples and acceptance rates
  • priorslist with prior specifications
  • v.phituning parameter for $phi$
  • initialslist with initial values
  • modelname of the specified model
  • nburninnumber of burnin iterations
  • nsamplesnumber of returned samples
  • thinused thinning factor

See Also

demo("fecm", package = "eggCounts")