strip.default
Default Trellis Strip Function
strip.default
is the function that draws the strips by default
in Trellis plots. Users can write their own strip functions, but most
commonly this involves calling strip.default
with a slightly
different arguments. strip.custom
provides a convenient way to
obtain new strip functions that differ from strip.default
only
in the default values of certain arguments.
- Keywords
- dplot
Usage
strip.default(which.given,
which.panel, var.name,
factor.levels,
shingle.intervals,
strip.names = c(FALSE, TRUE),
strip.levels = c(TRUE, FALSE),
sep = " : ",
style = 1,
horizontal = TRUE,
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"))
strip.custom(...)
Details
default strip function for trellis functions. Useful
mostly because of the style
argument --- non-default styles
are often more informative, especially when the names of the levels
of the factor x
are small. Traditional use is as
strip = function(...) strip.default(style=2,...)
, though
this can be simplified by the use of strip.custom
.
Value
strip.default
is called for its side-effect, which is to draw a
strip appropriate for multi-panel Trellis conditioning plots.
strip.custom
returns a function that is similar to
strip.default
, but with different defaults for the arguments
specified in the call.
See Also
Examples
## Traditional use
xyplot(Petal.Length ~ Petal.Width | Species, iris,
strip = function(..., style) strip.default(..., style = 4))
## equivalent call using strip.custom
xyplot(Petal.Length ~ Petal.Width | Species, iris,
strip = strip.custom(style = 4))
xyplot(Petal.Length ~ Petal.Width | Species, iris,
strip = FALSE,
strip.left = strip.custom(style = 4, horizontal = FALSE))