Learn R Programming

lmerTest (version 1.2-1)

merLmerTest-class: Mixed Model Representations

Description

The merLmerTest contains mer class of lme4 package and overloads anova and summary functions. The summary.merLmerTest class represents the summary of objects of class merLmerTest. The "summary.merLmerTest" class contains the "summary.mer"

Arguments

Objects from the Class

Objects can be created via the lmer functions.

Methods

anova signature(object = "merLmerTest", ...): returns the data frame with F test of type 3 hypothesis for each term in formula and corresponding p-values. For multiple arguments, model comparison statistics. The definition of type 3 hypothesis comes from SAS theory proc mixed. The approximations for degrees of freedom by default are Satterthwaite's (ddf="Satterthwaite"). If ddf="Kenward-Roger", then the Kenward-Roger's approximations are calculated using KRmodcomp function from pbkrtest package. If ddf="lme4" then the anova table that comes from lme4 package is returned. method.grad is an argument for the approximation method for the grad function, which is used in calculation of denominator degrees of freedom. method.grad could be "simple" or "Richardson". method.grad="simple" is the default one and the fastest one, method.grad="Richardson" gives more accurate results. anova

See Also

lmer()

Examples

Run this code
(m <- lmer(Reaction ~ Days + (1|Subject) + (0+Days|Subject),
             data = sleepstudy))

# anova table with additional F statistics and denominator degrees of freedom
# calculated based on Satterthwaite's approximation
anova(m)

# anova table with additional F statistics and denominator degrees of freedom
# calculated based on Kenward-Roger's approximation
anova(m, ddf="Kenward-Roger")

# anova table, that is returned by lme4 package
anova(m, ddf="lme4")

# summary of merLmerTest object. Returns the same as mer object but with an 
#additional column of p values for the t test. 
summary(m)

Run the code above in your browser using DataLab