Description Usage Arguments Details References Examples
A wrapper around 'graphics::pairs()' that includes correlation estimates on the lower diagonal and a [stats::lowess()] smooth of the scatterplots on the upper triangle with [graphics::panel.smooth()].
1 2 | pairsWithCor(x, use = "everything", method = c("pearson", "kendall",
"spearman"), ...)
|
x |
the coordinates of points given as numeric columns of a
matrix or data frame. Logical and factor columns are converted to
numeric in the same way that |
use |
an optional character string giving a
method for computing covariances in the presence
of missing values. This must be (an abbreviation of) one of the strings
|
method |
a character string indicating which correlation
coefficient (or covariance) is to be computed. One of
|
... |
arguments to be passed to or from methods. Also, graphical parameters can be given as can arguments to
|
The ijth scatterplot contains x[,i]
plotted against
x[,j]
. The scatterplot can be customised by setting panel
functions to appear as something completely different. The
off-diagonal panel functions are passed the appropriate columns of
x
as x
and y
: the diagonal panel function (if
any) is passed a single column, and the text.panel
function is
passed a single (x, y)
location and the column name.
Setting some of these panel functions to NULL
is
equivalent to not drawing anything there.
The graphical parameters pch
and col
can be used
to specify a vector of plotting symbols and colors to be used in the
plots.
The graphical parameter oma
will be set by
pairs.default
unless supplied as an argument.
A panel function should not attempt to start a new plot, but just plot
within a given coordinate system: thus plot
and boxplot
are not panel functions.
By default, missing values are passed to the panel functions and will
often be ignored within a panel. However, for the formula method and
na.action = na.omit
, all cases which contain a missing values for
any of the variables are omitted completely (including when the scales
are selected).
Arguments horInd
and verInd
were introduced in R
3.2.0. If given the same value they can be used to select or re-order
variables: with different ranges of consecutive values they can be
used to plot rectangular windows of a full pairs plot; in the latter
case ‘diagonal’ refers to the diagonal of the full plot.
Becker, R. A., Chambers, J. M. and Wilks, A. R. (1988) The New S Language. Wadsworth & Brooks/Cole.
1 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.