Learn R Programming

segmented (version 2.2-1)

plot.segmented.lme: Plot method for segmented mixed objects

Description

Takes a fitted segmented.lme object returned by segmented.lme() and plots (or adds) the fitted broken-line relationship for the segmented term.

Usage

# S3 method for segmented.lme
plot(x, level=1, id = NULL, res = TRUE, pop = FALSE, offs=0, yscale = 1, xscale = 1, 
    n.plot, pos.leg = "topright", vline = FALSE, lines = TRUE, 
    by=NULL, add=FALSE, conf.level=0, withI=TRUE, vcov.=NULL, shade=FALSE, 
    drop.var=NULL, text.leg=NULL, id.name=TRUE, ci.psi.pop=-1, ...)

Arguments

Value

A single or multiple (depending on level and id) plot showing the fitted segmented profiles.

Details

The function plots the 'subject'-specific segmented profiles for the 'subjects' specificed in id or, if level=0, the fitted segmented relationship based on fixed effects only. The number of panels to drawn is actually the minimum between length(id) and prod(n.plot), but if n.plot=c(1,1) (or also simply n.plot=1), the `individual' profiles will be pictured on the same panel.

See Also

segmented.lme

Examples

Run this code
if (FALSE) {
#continues example from segmented.lme

plot(os, yscale=-1) #different y-scales

plot(os2, n.plot=1, l.col=2:6, l.lwd=2) #all segmented profiles on the same plot

}

Run the code above in your browser using DataLab