plot.rlmerMod {robustlmm} | R Documentation |
Plot Method for "rlmerMod" objects.
Description
Diagnostic plots for objects of class rlmerMod
and lmerMod
.
Usage
## S3 method for class 'rlmerMod'
plot(
x,
y = NULL,
which = 1:4,
title = c("Fitted Values vs. Residuals", "Normal Q-Q vs. Residuals",
"Normal Q-Q vs. Random Effects", "Scatterplot of Random Effects for Group \"%s\""),
multiply.weights = FALSE,
add.line = c("above", "below", "none"),
...
)
## S3 method for class 'rlmerMod_plots'
print(x, ask = interactive() & length(x) > 1, ...)
Arguments
x |
an object as created by |
y |
currently ignored. |
which |
integer number between 1 and 4 to specify which plot is desired. |
title |
Titles for the different plots. The fourth item can be a format
string passed to |
multiply.weights |
multiply the residuals / random effects with the robustness weights when producing the Q-Q plots. |
add.line |
add reference line to plots, use |
... |
passed on to |
ask |
waits for user input before displaying each plot. |
Details
The robustness weights for estimating the fixed and random effects are used
in the plots, e.g., the ones returned by getME(object, "w_e")
and
getME(object, "w_b")
.
Value
a list of plots of class ggplot
that can be
used for further modification before plotting (using print
).
See Also
Examples
## Not run:
rfm <- rlmer(Yield ~ (1|Batch), Dyestuff)
plot(rfm)
fm <- lmer(Reaction ~ Days + (Days|Subject), sleepstudy)
plot.rlmerMod(fm)
## End(Not run)