Rdocumentation
powered by
Learn R Programming
⚠️
There's a newer version (2.4) of this package.
Take me there.
eggCounts (version 0.4-1)
Hierarchical Modelling of Faecal Egg Counts
Description
An implementation of hierarchical models for faecal egg count data to assess anthelmintic efficacy. Bayesian inference is done via MCMC sampling.
Copy Link
Link to current version
Version
Version
2.4
2.3-4
2.3-3
2.3-2
2.3-1
2.3
2.2-1
2.2
2.1-2
2.1-1
2.1
2.0
1.4
1.3
1.2
1.1-2
1.1-1
1.1
1.0
0.4-1
0.3
0.2
Install
install.packages('eggCounts')
Monthly Downloads
323
Version
0.4-1
License
GPL (>= 2)
Maintainer
Reinhard Furrer
Last Published
February 13th, 2015
Functions in eggCounts (0.4-1)
Search all functions
checkAR
Check acceptance rates
MHstep
Do a Metropolis-Hastings step
fecr_mcmc
Modelling of Faecal Egg Count data (two-sample case)
fecrtCI
Compute standard FECRT according to WAAVP guidelines
setDefaults1
Set default values for the one-sample (ZI)PoGa model formulation
modeCurvature_h
Compute mode and curvature at the mode of a full conditional of form $h(x) = x^{-a} \exp(-bx -c/x)$
echinococcus
Faecal egg count sample
MH_RW_unif
MH step with uniform (truncated at 0) proposal around the current value
setInitials2
Set initial values for all parameters of the two-sample (ZI)PoGa model
eggCounts-package
Hierarchical modelling of faecal egg counts
samples2mcmc
Convert the list with samples to a
mcmc
object
simData1s
Simulate faecal egg count data (1-sample situation)
setDefaults2
Set default values for the two-sample (ZI)PoGa model formulation
logdgammaMixture
Compute log density of a gamma mixture
setUpdates_ZIPoGa_u
Specify parameter updates for ZIPoGa_u (2-sample) model
setInitials1
Set initial values for all parameters of the one-sample (ZI)PoGa model
modeCurvature_phi
Numerically compute mode and curvature at the mode of a full conditional for $\phi$ of form -(n*phi+a-1)*log(phi) + n*lgamma(phi) + n*phi*log(mu)- (phi-1)*logprodmu + phi*(summu.mu+b)
setUpdates_ZIPoGa_mu
Specify parameter updates for PoGa (1-sample) model
epgs
Faecal egg count samples (before and after treatment)
update_theta_gammaMix
Update a parameter vector theta $theta_1,\ldots,theta_n$ based on a gamma mixture distribution
statusMsg
Print information about the progress of the MCMC run
simData2s
Simulate faecal egg count data (2-sample situation)
fec_mcmc
Modelling of Faecal Egg Count data (one-sample case)
update_h_logNormal
Update the parameter $theta$ (with FC of form h) using a lognormal approximation to the FC as proposal
update_phi_unif
Update the overdispersion parameter $phi$ using a uniform random walk proposal
setUpdates_PoGa_mu
Specify parameter updates for PoGa (1-sample) model
update_theta_beta
Update a parameter $theta$ based on a beta distribution
update_theta_gammaAdd
Update a parameter vector theta $theta_1,\ldots,theta_n$ based on a gamma distribution using a gamma proposal with slightly shifted shape parameter to avoid to small theta
update_Y
Update latent egg counts $y_1,\ldots,y_n$ based on a truncated Poisson distribution
update_psi_beta
Update the zero-inflation parameter $psi$ using a beta approximation to the FC as proposal
setUpdates_ZIPoGa2
Specify parameter updates for PoGa2 (1-sample) model
setUpdates_PoGa_u
Specify parameter updates for PoGa_u (unpaired 2-sample) model
update_theta_gamma1
Update a parameter $theta$ based on a gamma distribution
update_h_gamma
Update the parameter $theta$ (with FC of form $h(x) = x^{-a} \exp(-bx -c/x)$) using a gamma approximation to the FC as proposal
update_delta_beta
Update the reduction in mean parameter $delta$ using a beta approximation to the FC as proposal
update_theta_gamma
Update a parameter vector theta $theta_1,\ldots,theta_n$ based on a gamma distribution
setUpdates_PoGa2
Specify parameter updates for PoGa2 (1-sample) model
modeCurvature_delta
Compute mode and curvature at the mode of a full conditional of form $h(x) = x^{a} (1-x)^{b} \exp(-c x)$
tab1morgan
Abundance of trichostrongyloid eggs in sheep faeces
update_phi_gamma
Update the overdispersion parameter $phi$ using a gamma approximation to the FC as proposal
print.fecrm
Print information about mcmc run
fc_approx_logNormal
Approximate a full conditional with given mode and curvature by a log normal distribution
MH_RW_unif01
MH step with uniform (truncated at 0 and 1) proposal around the current value
setUpdates_PoGa_p
Specify parameter updates for PoGa_p (paired 2-sample) model
modeCurvature_psi
Compute mode and curvature at the mode of a full conditional of form $h(x) = (1-d x)^{a} (1-x)^{b} x^{c}$
print.fecm
Print information about mcmc run
update_h_invGamma
Update the parameter $theta$ (with FC of form h) using an inverse gamma approximation to the FC as proposal
fc_approx_beta
Approximate a full conditional with given mode and curvature by a beta distribution
fc_approx_invgamma
Approximate a full conditional with given mode and curvature by an inverse gamma distribution
fc_approx_gamma
Approximate a full conditional with given mode and curvature by a gamma distribution
setUpdates_ZIPoGa_u_pd
Specify parameter updates for ZIPoGa_u_pd (2-sample) model
update_h_kl
Update the parameter $theta$ (with FC of form $h(x) = x^{-a} \exp(-bx -c/x)$)) using eiter a gamma or an inverse gamma approximation to the FC as proposal depending on which distribution has smaller KL divergence.