lcc
ObjectCompare Likelihoods of Fitted Models from an lcc
Object
# S3 method for lcc
anova(object, ..., test, type, adjustSigma,
verbose)
If just one lcc
model object is declared, a data
frame with the numerator degrees of freedom, denominator degrees
of freedom, F-values, and P-values for the fixed terms in the
model. Otherwise, when multiple lcc
fitted objects are
being compared, a data frame with the degrees of freedom, the
(restricted) log-likelihood, the Akaike Information Criterion
(AIC), and the Bayesian Information Criterion (BIC) of each object
is returned.
an object inheriting from class lcc
or lme
,
representing a fitted longitudinal concordance correlation
function.
other optional fitted model objects inheriting from classes "lcc", or "lme".
an optional logical value controlling whether likelihood
ratio tests should be used to compare the fitted models
represented by object and the objects in ...
. Defaults to
TRUE.
an optional character string specifying the type of sum
of squares to be used in F-tests for the terms in the model. If
sequential
, the sequential sum of squares obtained by
including the terms in the order they appear in the model is used;
else, if marginal
, the marginal sum of squares obtained by
deleting a term from the model at a time is used. This argument is
only used when a single fitted object is passed to the
function. Partial matching of arguments is used, so only the first
character needs to be provided. Defaults to sequential
.
an optional logical value. If TRUE
and the
estimation method used to obtain object was maximum likelihood,
the residual standard error is multiplied by sqrt(nobs/(nobs -
npar)), converting it to a REML-like estimate. This argument is
only used when a single fitted object is passed to the
function. Default is TRUE
.
an optional logical value. If TRUE
, the
calling sequences for each fitted model object are printed with
the rest of the output, being omitted if verbose =
FALSE
. Defaults to FALSE
.
Thiago de Paula Oliveira, thiago.paula.oliveira@alumni.usp.br
This function is an adaptation from the
anova.lme
. For more details see methods for
nlme
.
lcc
, summary.lcc
if (FALSE) {
## Testing random effects
fm1.aov <- lcc(data = hue, subject = "Fruit", resp = "H_mean",
method = "Method", time = "Time", qf = 2, qr = 1)
fm2.aov <- update(fm1.aov, qr = 2)
anova(fm1.aov, fm2.aov)
}
if (FALSE) {
# Testing fixed effects
fm3.aov <- update(fm2.aov, REML = FALSE)
fm4.aov <- update(fm2.aov, REML = FALSE, qf = 3)
anova(fm3.aov, fm4.aov)
}
if (FALSE) {
# Comparing the 3 lcc models
fm5.aov <- update(fm2.aov, var.class = varExp, weights.form = "time")
anova(fm1.aov, fm2.aov, fm5.aov)
}
Run the code above in your browser using DataLab