Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

plots.thpr

Mixed-Effects Profile Plots (Regular / Density / Pairs)


Description

Xyplot, Densityplot, and Pairs plot methods for a mixed-effects model profile.

xyplot() draws “zeta diagrams”, also visualizing confidence intervals and their asymmetry.

densityplot() draws the profile densities.

splom() draws profile pairs plots. Contours are for the marginal two-dimensional regions (i.e. using df = 2).

Usage

## S3 method for class 'thpr'
xyplot(x, data = NULL,
       levels = sqrt(qchisq(pmax.int(0, pmin.int(1, conf)), df = 1)),
       conf = c(50, 80, 90, 95, 99)/100,
       absVal = FALSE, scales=NULL,
       which = 1:nptot, ...)

## S3 method for class 'thpr'
densityplot(x, data, npts = 201, upper = 0.999, ...)

## S3 method for class 'thpr'
splom(x, data,
      levels = sqrt(qchisq(pmax.int(0, pmin.int(1, conf)), 2)),
      conf = c(50, 80, 90, 95, 99)/100,  which = 1:nptot,
      draw.lower = TRUE, draw.upper = TRUE, ...)

Arguments

x

a mixed-effects profile, i.e., of class "thpr", typically resulting from profile(fm) where fm is a fitted model from lmer (or its generalizations).

data

unused - only for compatibility with generic.

npts

the number of points to use for the densityplot().

upper

a number in (0,1) to specify upper (and lower) boundaries as +/- qnorm(upper).

levels

the contour levels to be shown; usually derived from conf.

conf

numeric vector of confidence levels to be shown as contours.

absVal

logical indicating if abs(.)olute values should be plotted, often preferred for confidence interval visualization.

scales

plotting options to be passed to xyplot

which

integer or character vector indicating which parameters to profile: default is all parameters (see profile-methods for details).

draw.lower

(logical) draw lower-triangle (zeta scale) panels?

draw.upper

(logical) draw upper-triangle (standard dev/cor scale) panels?

...

further arguments passed to xyplot, densityplot, or splom from package lattice, respectively.

Value

xyplot:

a density plot, a "trellis" object (lattice package) which when print()ed produces plots on the current graphic device.

densityplot:

a density plot, a "trellis" object, see above.

splom:

a pairs plot, aka scatterplot matrix, a "trellis" object, see above.

See Also

profile, notably for an example.

Examples

## see   example("profile.merMod")

lme4

Linear Mixed-Effects Models using 'Eigen' and S4

v1.1-26
GPL (>= 2)
Authors
Douglas Bates [aut] (<https://orcid.org/0000-0001-8316-9503>), Martin Maechler [aut] (<https://orcid.org/0000-0002-8685-9910>), Ben Bolker [aut, cre] (<https://orcid.org/0000-0002-2127-0443>), Steven Walker [aut] (<https://orcid.org/0000-0002-4394-9078>), Rune Haubo Bojesen Christensen [ctb] (<https://orcid.org/0000-0002-4494-3399>), Henrik Singmann [ctb] (<https://orcid.org/0000-0002-4842-3657>), Bin Dai [ctb], Fabian Scheipl [ctb] (<https://orcid.org/0000-0001-8172-3603>), Gabor Grothendieck [ctb], Peter Green [ctb] (<https://orcid.org/0000-0002-0238-9852>), John Fox [ctb], Alexander Bauer [ctb], Pavel N. Krivitsky [ctb, cph] (<https://orcid.org/0000-0002-9101-3362>, shared copyright on simulate.formula)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.