plyx {plgraphics} | R Documentation |
Scatterplot, enhanced
Description
A scatterplot or a bunch of them is produced according to the concept of the plplot package
Usage
plyx(x = NULL, y = NULL, by=NULL, group = NULL, data = NULL, type = "p",
panel = NULL, xlab = NULL, ylab = NULL, xlim = NULL, ylim = NULL,
markextremes = 0, rescale = TRUE, mar = NULL, mf = FALSE,
plargs = NULL, ploptions = NULL, assign = TRUE, ...)
Arguments
x |
either a formula or the data to be used for the horizontal axis. If a formula of the type 'y~x', the variable 'y' in 'data' will be plotted against the variable(s) 'x'. If a data.frame with more than one column is given, each column will be used in turn to produce a plot. |
y |
data to be used as the y axis. |
by |
grouping factor: for each |
group |
grouping that determines plotting symbols, colors, and line types |
data |
data.frame containing the variables if 'x' is a formula |
xlab , ylab |
axis labels |
xlim , ylim |
plot ranges |
type |
type of plot, see |
panel |
panel function to do the actual drawing. See Details. |
markextremes |
proportion of extreme residuals to be labeled.
If all points should be labeled, let |
rescale |
logical. Only applies if there are multiple y
variables. If |
mar |
plot margins, see |
mf |
number of multiple frames. If more than one plot will be
generated because of a grouping or multiple x variables,
multiple frames will be produced by calling |
plargs |
result of calling |
ploptions |
list of pl options. |
assign |
logical: Should the plargs be stored
in the |
... |
more arguments, to be passed to |
Details
panel
defaults to plpanel
, which results essentially in
points
or text
depending on the argument pch
including a smooth line,
to plmboxes
if 'x' is a factor and 'y' is not or
vice versa,
or to a modification of sunflowers
if both are factors.
The function must have the arguments x
and y
to take the coordinates of the points and may have the arguments
indx
and indy
to transfer the two variables' indexes and
panelargs
for any additional objects to be passed on.
Value
None.
Note
There are many more arguments, obtained from pl.control
,
see ?pl.control
. These can be passed to plmatrix
by an argument plargs
that is hidden in the ... argument list.
Author(s)
Werner A. Stahel, ETH Zurich
See Also
plmatrix
, plcond
;
pl.control
, ploptions
Examples
plyx(Petal.Width ~ Sepal.Length, data=iris)
plyx(Petal.Width ~ Sepal.Length+Sepal.Width, data=iris, smooth=TRUE,
group=Species)
plyx(Petal.Length + Petal.Width ~ Sepal.Length+Sepal.Width,
by = Species, data=iris, smooth=TRUE)