aod (version 1.3.3)

anova-methods: Likelihood-Ratio Tests for Nested ML Models

Description

Performs likelihood-ratio tests on nested models. Currently, one method was implemented for beta-binomial models (betabin) or negative-binomial models (negbin).

Usage

# S4 method for glimML
anova(object, ...)

Value

An object of formal class “anova.glimML” with 3 slots:

models

A vector of character strings with each component giving the name of the models and the formulas for the fixed and random effects.

anova.table

A data frame containing the results. Row names correspond to the models.

logLnumericmaximized log-likelihood
knumericnumber of parameters in the model
AICnumericAkaike information criterion for the model
AICcnumericCorrected Akaike information criterion for the model
BICnumericBayesian information criterion the model
Resid. dev.numericResidual deviance
Resid. Dfnumericdf of the residuals
TestcharacterNested models which are tested
DeviancenumericDeviance difference between the 2 models
Dfnumericdf associated with deviance difference
P(> Chi2)numericP value associated with H0.

type

A character chain indicating the kind of fitted model: “BB” for beta-binomial, or “NB” for negative-binomial model.

Arguments

object

Fitted model of class “glimML”.

...

Further models to be tested or arguments passed to the print function.

Warning

The comparison between 2 or more models will only be valid if they are fitted to the same data set.

Details

The anova method for models of formal class “glimML” needs at least 2 nested models of the same type (either beta-binomial or negative-binomial models: they cannot be mixed). The quantity of interest is the deviance difference between the compared models: it is a log-likelihood ratio statistic. Under the null hypothesis that 2 nested models fit the data equally well, the deviance difference has an approximate \(\chi^2\) distribution with degrees of freedom = the difference in the number of parameters between the compared models (Mc Cullagh and Nelder, 1989).

References

McCullagh, P., Nelder, J.A., 1989. Generalized linear models. London, Chapman & Hall, 511 p.
See Appendix C. Likelihood ratio statistics, p. 476-478.

See Also

Examples

Run this code
  data(orob2)
  # likelihood ratio test for the effect of root
  fm1 <- betabin(cbind(y, n - y) ~ seed, ~ 1, data = orob2)
  fm2 <- betabin(cbind(y, n - y) ~ seed + root, ~ 1, data = orob2)
  anova(fm1, fm2)
  

Run the code above in your browser using DataLab