rpt.binomGLMM.add: GLMM-based Repeatability Using MCMC for Binomial Data

Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/rpt.binomGLMM.add.R

Description

Calculates repeatability from a generalised linear mixed-effects models fitted by MCMC for binary and proportion data

Usage

1
rpt.binomGLMM.add(y, groups, CI=0.95, prior=NULL, verbose=FALSE, ...)

Arguments

y

Vector of a response values (for binary data) or a two-column matrix, array or data.frame with colums m, n-m, where m is the number of successes and n the number of trials.

groups

Vector of group identities.

CI

Width of the Bayesian credible interval (defaults to 0.95)

prior

List of prior values passed to the MCMCglmm function in MCMCglmm (see there for more details). Default priors will be used if prior is NULL.

verbose

Whether or not MCMCglmm should print MH diagnostics are printed to screen. Defaults to FALSE.

...

Additonal arguements that are passed on to MCMCglmm (e.g. length of chain, thinning interval).

Details

Models are fitted using the MCMCglmm function in MCMCglmm. The categorical family is used for binary data, while the multinomial2 is used for proportion data. Models for binary data are fitted with list(R=list(V=1,fix=1),G=list(G1=list(V=1,nu=1,alpha.mu=0,alpha.V=25^2))) unless other priors are specified in the call. Models for proportion data are fitted with list(R=list(V=1e-10,nu=-1),G=list(G1=list(V=1,nu=1,alpha.mu=0,alpha.V=25^2))) unless other priors are specified in the call.

Value

Returns an object of class rpt that is a a list with the following elements:

datatype

Type of response (here: "binomial").

method

Method used to calculate repeatability (here: "MCMC").

CI

Width of the Bayesian credibility interval.

R.link

Point estimate for repeatability on the link scale, i.e. the mode of the posterior distribution.

se.link

Standard error (se) for the repeatability on the link scale, i.e. the standard deviation of the posterior distribution. Note that the distribution might not be symmetrical, in which case se is less informative.

CI.link

Bayesian credibility interval for the intraclass correlation (or repeatability) on the link scale based on the posterior distribution of R.

P.link

Significance test for the link scale repeatability, returned as NA, since the Bayesian approach conflicts with the null hypothesis testing.

R.org

Point estimate for repeatability on the original scale, i.e. the mode of the posterior distribution.

se.org

Standard error (se) for repeatability on the original scale, i.e. the standard deviation of the posterior distribution. Note that the distribution might not be symmetrical, in which case se is less informative.

CI.org

Bayesian credibility interval for repeatability on the original scale based on the posterior distribution of R.

P.org

Significance test for the original scale repeatability, returned as NA, since the Bayesian approach conflicts with the null hypothesis testing.

R.post

Named list of MCMC samples form the posterior distributions. R.link gives the samples for the link scale repeatability, R.org gives the samples for the original scale repeatability.

Author(s)

Holger Schielzeth ([email protected]) & Shinichi Nakagawa ([email protected])

References

Browne, W. J., Subramanian, S. V., et al. (2005). Variance partitioning in multilevel logistic models that exhibit overdispersion. Journal of the Royal Statistical Society A 168: 599-613.

Goldstein, H., Browne, W., et al. (2002). Partitioning variation in multilevel models. Understanding Statistics 1: 223-231.

Nakagawa, S. and Schielzeth, H. (2010) Repeatability for Gaussian and non-Gaussian data: a practical guide for biologists. Biological Reviews 85: 935-956

See Also

rpt.binomGLMM.multi, rpt, print.rpt

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
# repeatability estimations for egg dumping (binary data)
data(BroodParasitism)
attach(BroodParasitism)
(rpt.Host <- rpt.binomGLMM.add(HostYN[OwnClutchesBothSeasons==1], FemaleID[OwnClutchesBothSeasons==1]))
(rpt.BroodPar <- rpt.binomGLMM.add(cbpYN, FemaleID))
detach(BroodParasitism)

# repeatability estimations for egg dumping (proportion data)
data(BroodParasitism)
attach(BroodParasitism)
ParasitisedOR <- cbind(HostClutches, OwnClutches-HostClutches)
(rpt.Host <- rpt.binomGLMM.add(ParasitisedOR[OwnClutchesBothSeasons==1,], 
	FemaleID[OwnClutchesBothSeasons==1]))
ParasitismOR <- cbind(cbpEggs, nEggs-cbpEggs)   
(rpt.BroodPar <- rpt.binomGLMM.add(ParasitismOR, FemaleID))
detach(BroodParasitism)

rptR documentation built on May 31, 2017, 2:53 a.m.