mayplot | R Documentation |
Produces a matrix-like plot for arrays up to rank 5,
using grid and gridBase which allows traditional
graphics, optionally via a user specified panel function
panel
.
mayplot(x, vList, row.vars = NULL, col.vars = NULL,
xvar, method = if(has.n.sim) "boxplot" else "lines",
panel.first = NULL, panel.last = NULL,
type = "l", pch = NULL, ylim = "global",
log = "", do.legend = TRUE,
spc = c(0.04/max(1,n.x-1), 0.04/max(1,n.y-1)),
axlabspc=c(0.12, 0.08), labspc=c(0.04, 0.04),
n.sim.spc = 0.06, auxcol = c("gray40", "gray78", "gray90", "white"),
pcol = c("black", "blue", "red", "orange"), grid.lwd = 1.6, ax.lwd = 2,
tx.cex = 1.2, leg.cex = 1, xlab = NULL, ylab = NA,
do.n.sim = has.n.sim,
verbose = getOption("verbose"), show.layout = verbose, ...)
x |
numeric |
vList |
a |
row.vars |
a dimension name of |
col.vars |
a dimension name of |
xvar |
dimension name of |
method |
|
panel.first, panel.last |
|
type |
character indicating the type of plotting in the
non-boxplot case; actually any of the |
pch |
|
ylim |
either string |
log |
|
do.legend |
|
spc |
dimensions (x, y) in “npc” for the space between sub-plots. The default uses a simple adaption to the number of sub-plots in each direction. |
axlabspc |
vector of length two containing the width of the y axis label and the height of the x axis label in “npc”. |
labspc |
vector of length two containing the width of the box of the row labels and the height of the box of the column labels in “npc”. |
n.sim.spc |
space for |
auxcol |
auxiliary colors; vector with four components:
|
pcol |
plot base colors. If more colors than the provided ones
are required, |
grid.lwd |
lwd for grid |
ax.lwd |
lwd for axes |
tx.cex |
cex for row and column labels |
leg.cex |
cex of legend text and |
xlab |
x axis label (spanned over all plot columns); when
|
ylab |
y axis label (spanned over all plot rows): Typically a
label for the |
do.n.sim |
|
verbose |
logical indicating whether more information is displayed during plotting. |
show.layout |
logical indicating whether the grid layout is displayed. |
... |
optional arguments passed to |
the layout, invisibly.
Marius Hofert and Martin Maechler.
matplot
unit
and grid.layout
from
package grid.
vLis <-
varlist(d = list(type="grid", value = c(10, 100, 1000)),
family=list(type="grid", value = c("Clayton", "Gumbel")),
tau = list(type="grid", value = c(0.25, 0.5)),
alpha = list(type="inner", value = c(0.95, 0.99, 0.999)))
iP <- c(4, 1:3)# <- permutation, putting alpha first
dNms <- mkNms(vLis)[iP]
## an array as from x <- getArray( doMclapply(vLis, ..) ) :
x <- array(
c(6.1981, 8.0478, 8.4265, 46.883, 74.359, 86.4394, 432.585, 743.27, 859.35,
4.8508, 6.0286, 6.3965, 26.380, 35.132, 47.1517, 243.113, 311.36, 342.84,
7.8546, 8.9769, 9.2199, 78.235, 89.493, 92.2875, 785.674, 893.63, 923.62,
7.7164, 8.2866, 8.8169, 75.959, 82.806, 88.0626, 756.786, 831.65, 874.70),
dim = sapply(dNms, length), dimnames = dNms)
mayplot(x, vLis, row.vars="family", col.vars="tau", xvar="alpha", log="y",
ylab=bquote(widehat(VaR)[alpha]))
## the same, but no xlab and no ylab :
mayplot(x, vLis, row.vars="family", col.vars="tau", xvar="alpha", log="y", xlab=NA)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.