anova.caic | R Documentation |
These functions provide ANOVA tables and model comparison using ANOVA and AIC, along with standard model diagnostic plots and accessor functions for phylogenetic independent contrast objects.
## S3 method for class 'caic'
anova(object, ...)
## S3 method for class 'caiclist'
anova(object, ..., scale=0, test='F')
## S3 method for class 'caic'
logLik(object, ...)
## S3 method for class 'caic'
predict(object, ...)
## S3 method for class 'caic'
residuals(object, ...)
## S3 method for class 'caic'
coef(object, ...)
## S3 method for class 'caic'
plot(x, ...)
object |
An object of class 'caic'. |
scale |
A character string specifying the test statistic to be used. Can be one of "F", "Chisq" or "Cp", with partial matching allowed, or NULL for no test. |
test |
numeric. An estimate of the noise variance sigma^2. If zero this will be estimated from the largest model considered. |
x |
An object of class 'caic'. |
... |
Further argument to be passed to methods. |
The 'anova' method provides access to single anova tables for a model and to comparison of lists of models. The 'logLik' method provides access to the log likelihood of the 'caic' model and hence to AIC comparison of models.
The 'plot' method uses the standard set of model diagnostic plots for linear models. It is also wise to check the evolutionary assumptions of independent contrast models using the 'caic' specific diagnostic plots. The 'predict' and 'residuals' functions provide access to these parts of the 'caic' object.
David Orme
crunch
, brunch
,macrocaic
,caic.diagnostics
data(shorebird)
shorebird.data$lgEgg.Mass <- log(shorebird.data$Egg.Mass)
shorebird.data$lgM.Mass <- log(shorebird.data$M.Mass)
shorebird.data$lgF.Mass <- log(shorebird.data$F.Mass)
shorebird <- comparative.data(shorebird.tree, shorebird.data, Species)
cMod1 <- crunch(lgEgg.Mass ~ lgM.Mass * lgF.Mass, data=shorebird)
cMod2 <- crunch(lgEgg.Mass ~ lgM.Mass + lgF.Mass, data=shorebird)
cMod3 <- crunch(lgEgg.Mass ~ lgM.Mass , data=shorebird)
anova(cMod1, cMod2, cMod3)
AIC(cMod1, cMod2, cMod3)
plot(cMod3)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.