trellis.par.get(name = NULL)
trellis.par.set(name, value, warn)
trellis.par.set(theme)
trellis.par.set(...)
show.settings(x = NULL)
names(trellis.par.get())
returns a list containing all the
current settings (this can be used to get the valid values for
name
)value
will remain unchanged.trellis.par.get()
. This is purely for
convenience, allowing multiple calls to trellis.par.set
to be
condensed into one. The name of each coname = value
form.
Equivalent to calling with theme = list(...)
trellis.par.get
is called when no graphics device is opentheme
). These are used to modify the current
settings (obtained by trellis.par.get
) before they are
displayed.trellis.par.get
returns a list giving parameters for that
component. If name
is missing, it returns the full list.lattice.theme
, which is a list whose components
define settings for particular devices. The components are idenified
by the name of the device they represent (as obtained by
.Device
), and are created as and when new devices are opened
for the first time using trellis.device
(or Lattice plots are
drawn on a device for the first time in that session). The initial settings for each device defaults to values appropriate
for that device. In practice, this boils down to three distinct
settings, one for screen devices like x11
and windows
,
one for black and white plots (mostly useful for postscript
)
and one for color printers (color postcript
, pdf
).
Once a device is open, it's settings can be modified. When another
instance of the same device is opened later using
trellis.device
, the settings for that device are reset to its
defaults, unless otherwise specified in the call to
trellis.device
. But settings for different devices are treated
separately, i.e., opening a postscript device will not alter the x11
settings, which will remain in effect whenever an x11 device is
active.
The functions trellis.par.*
are meant to be interfaces to the
global settings. They always apply on the settings for the currently
ACTIVE device.
trellis.par.get
, called without any arguments, returns the full
list of settings for the active device. With the name
argument
present, it returns that component only. trellis.par.get
sets
the value of the name
component of the current active device
settings to value
.
trellis.par.get
is usually used inside trellis functions to get
graphical parameters before plotting. Modifications by users via
trellis.par.set
is traditionally done as follows:
add.line <- trellis.par.get("add.line")
add.line$col <- "red"
trellis.par.set("add.line", add.line)
More convenient (but not S compatible) ways to do this are
trellis.par.set(list(add.line = list(col = "red")))
and
trellis.par.set(add.line = list(col = "red"))
The actual list of the components in trellis.settings
has not
been finalized, so I'm not attempting to list them here. The current
value can be obtained by print(trellis.par.get())
. Most names
should be self-explanatory.
show.settings
provides a graphical display summarizing some of
the values in the current setting.
lset
. Other related pages: trellis.device
,
trellis.par.get
,Lattice