Learn R Programming

TeachingDemos (version 1.2)

strip.shingle: strip function for trellis plots

Description

The strip.shingle function is a modification of strip.default that shows the range of each shingle in the panel strips as well as the name of the shingle variable. This function is now depricated, you can do the same thing with strip.custom now, see the example below.

Usage

strip.shingle(which.given, which.panel, var.name, factor.levels, shingle.intervals, strip.names = c(FALSE, TRUE), style = 1, bg = trellis.par.get("strip.background")$col[which.given], fg = trellis.par.get("strip.shingle")$col[which.given], par.strip.text = trellis.par.get("add.text"),...)

Arguments

which.given
See strip.default.
which.panel
See strip.default.
var.name
See strip.default.
factor.levels
See strip.default.
shingle.intervals
See strip.default.
strip.names
See strip.default.
style
See strip.default.
bg
See strip.default.
fg
See strip.default.
par.strip.text
See strip.default.
...
Arguments passed through

Value

  • This function is only usefull for its side effects.

Details

Does the same as strip.default with the exception that by default when a shingle is used as the conditioning variable, the strip at the top of the panel will inclued the name of the conditioning variable and the range of the shingle for that plot. This function is now depricated, see the example below for the way to do the same thing using core lattice code.

See Also

strip.default, strip.custom

Examples

Run this code
library(lattice)
Depth <- equal.count(quakes$depth, number=8, overlap=.1)

# this is the old way, don't do this anymore use the example below
xyplot(lat ~ long | Depth, data = quakes, strip=strip.shingle)

xyplot(lat ~ long | Depth, data=quakes,
  strip=strip.custom(strip.names=TRUE, strip.levels=TRUE),
  par.strip.text=list(cex=0.75))

Run the code above in your browser using DataLab