Description Usage Arguments Details Examples
Designed to easily sets lattice parameters for multiple groups. Setting parameters before calling the lattice function allows parameters to be used consistently in the group key.
1 2 3 4 5 6 7 | td(new = FALSE, col = c("#0080ff", "#ff00ff", "darkgreen", "#ff0000", "orange", "#00ff00", "brown"), lty = 1:7, lwd = 1, pch = 1:7, cex = 0.8, font = 1, fill = "transparent", col.line = col, col.symbol = col, alpha = 1, alpha.line = alpha, alpha.symbol = alpha, len = 7, long = FALSE, record = FALSE, basecol = NULL, colsets = c("plot.symbol", "plot.line", "dot.symbol", "dot.line", "cloud.3d", "box.dot"), ...)
td(plot.symbol=list(col='red',pch=17))
td(plot.symbol=list(col='red',pch=17),plot.line=list(lwd=2))
gd(n=3)
|
n |
in 'gd' specifies the number of distinct colours to generate to distinguish groups. 'gd' uses 'latticeExtra' to set defaults for a ggplot2-like appearance. Default is n = 4 |
new |
If new = TRUE, open a new window, otherwise modify the existing active window, if there is one. |
col |
|
lty |
|
lwd |
|
pch |
|
cex |
vectors for graphical parameters for each level of the groups variable |
font |
|
fill |
|
col.line |
line colour if 'groups' not given |
col.symbol |
symbol colour if 'groups' not given |
alpha |
|
alpha.line |
|
alpha.symbol |
graphical parameters for superpose.line and superpose.symbol |
len |
extend the length of parameters by recycling to lenght 'len' |
long |
if TRUE generate a default combination of col, lty and pch with length 42. |
record |
If TRUE, set history to 'recording'. Caution: this can use a lot of memory in .GlobalEnv. Consider adding selected graphs to memory with the 'Insert' key instead. |
basecol |
|
colsets |
|
... |
use to set any trellis parameter: e.g. |
'td' calls 'trellis.device' and sets graphical parameters for 'superpose.line' and 'superpose.symbol'. 'td' also initializes a new trellis device with a white background if new = TRUE.
1 2 3 4 5 6 7 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.