# S3 method for lme
coef(object, augFrame, level, data, which, FUN,
omitGroupingFactor, subset, …)
"lme"
, representing
a fitted linear mixed-effects model.TRUE
, the returned
data frame is augmented with variables defined in data
; else,
if FALSE
, only the coefficients are returned. Defaults to
FALSE
.augFrame =
TRUE
. Defaults to the data frame used to fit object
.data
should be used in the
augmentation of the returned data frame. Defaults to all columns in
data
.data
by groups. Group-invariant variables are always summarized by the
unique value that they assume within that group. If FUN
is a
single function it will be applied to each non-invariant variable by
group to produce the summary for that variable. If FUN
is a
list of functions, the names in the list should designate classes of
variables in the frame such as ordered
, factor
, or
numeric
. The indicated function will be applied to any
group-varying variables of that class. The default functions to be
used are mean
for numeric factors, and Mode
for both
factor
and ordered
. The Mode
function, defined
internally in gsummary
, returns the modal or most popular
value of the variable. It is different from the mode
function
that returns the S-language mode of the variable.TRUE
the grouping factor itself will be omitted from the group-wise
summary of data
but the levels of the grouping factor will
continue to be used as the row names for the returned data frame.
Defaults to FALSE
."coef.lme"
with the estimated
coefficients at level level
and, optionally, other covariates
summarized over groups. The returned object also inherits from classes
"ranef.lme"
and "data.frame"
.lme
,
ranef.lme
,
plot.ranef.lme
, gsummary
fm1 <- lme(distance ~ age, Orthodont, random = ~ age | Subject)
coef(fm1)
coef(fm1, augFrame = TRUE)
Run the code above in your browser using DataLab