ranef | R Documentation |
Extract the conditional modes of the random effects from a fitted model object. For linear mixed models the conditional modes of the random effects are also the conditional means.
## S3 method for class 'remlf90'
ranef(object, ...)
object |
a fitted models with random effects of class
|
... |
not used |
This method is modeled a bit after ranef
. However, it is
independent and does not inherit from it. In particular, it always returns
the conditional variance (argument condVar in lme4).
An object of class ranef.breedR
composed of a list of vectors
or matrices (multitrait case), one for each random effect. The length of
the vectors are the number of levels of the corresponding random effect.
Each random effect has an attribute called "se"
which is a vector
with the standard errors.
Additionally, depending of the nature of the random effect, there may be further attributes. The pedigree will be given for genetic random effects and the spatial prediction grid for the spatial random effects
To produce a (list of) “caterpillar plots” of the random effects
apply plot
to the result of a call to ranef
.
res <- remlf90(phe_X ~ bl,
genetic = list(model = 'add_animal',
pedigree = globulus[, 1:3],
id = 'self'),
data = globulus)
str(rr <- ranef(res))
plot(rr)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.