pairs: Scatterplot Matrices

View source: R/pairs.R

pairsR Documentation

Scatterplot Matrices

Description

An enhanced version of the graphics::pairs function, incorporating some of the example code from the graphics::pairs help page to create upper and lower triangular split showing correlation coefficients and a trend line.

Usage

pairs(
  x,
  cor.method = "pearson",
  trendline = TRUE,
  loess = FALSE,
  span = 2/3,
  line.col = "darkred",
  gap = 0.5,
  ...
)

Arguments

x

A matrix or data/frame. Logical and factor columns are converted to numeric. Character columns are ignored.

cor.method

A character string indicating which correlation coefficient (or covariance) is to be computed. One of "pearson" (default), "kendall", or "spearman": can be abbreviated.

trendline

A logical argument specifying whether to include a linear trend line.

loess

A logical argument specifying whether to include a smoothed trend line.

gap

A distance between subplots, in margin lines.

...

Arguments to be passed to graphics::pairs.

col.smooth

A color to be used by lines for drawing the smooths.

Source

Dave Angelini david.r.angelini@gmail.com [aut, cre]

Examples


pairs(ChickWeight)


aphanotus/borealis documentation built on Nov. 4, 2022, 8:44 p.m.