gmatplot: Plot columns of matrices

gmatplotR Documentation

Plot columns of matrices

Description

Plot the columns of one matrix against the columns of another.

Usage

gmatplot(
  x,
  y,
  type = "p",
  lty = 1:5,
  lwd = 1,
  lend = par("lend"),
  pch = NULL,
  col = 1:6,
  cex = NULL,
  bg = NA,
  xlab = NULL,
  ylab = NULL,
  xlim = NULL,
  ylim = NULL,
  ...,
  add = FALSE,
  verbose = getOption("verbose"),
  grid = TRUE,
  col.grid = "grey90",
  col.acc = "white"
)

gmatpoints(
  x,
  y,
  type = "p",
  lty = 1:5,
  lwd = 1,
  pch = NULL,
  col = 1:6,
  ...,
  grid = TRUE,
  col.grid = "grey90",
  col.acc = "white"
)

gmatlines(
  x,
  y,
  type = "l",
  lty = 1:5,
  lwd = 1,
  pch = NULL,
  col = 1:6,
  ...,
  grid = TRUE,
  col.grid = "grey90",
  col.acc = "white"
)

Arguments

x, y

vectors or matrices of data for plotting. The number of rows should match. If one of them are missing, the other is taken as y and an x vector of 1:n is used. Missing values (NAs) are allowed. Since R 4.0.0, class(.)es of x and y such as "Date" are typically preserved.

type

character string (length 1 vector) or vector of 1-character strings indicating the type of plot for each column of y, see plot for all possible types. The first character of type defines the first plot, the second character the second, etc. Characters in type are cycled through; e.g., "pl" alternately plots points and lines.

lty, lwd, lend

vector of line types, widths, and end styles. The first element is for the first column, the second element for the second column, etc., even if lines are not plotted for all columns. Line types will be used cyclically until all plots are drawn.

pch

character string or vector of 1-characters or integers for plotting characters, see points for details. The first character is the plotting-character for the first plot, the second for the second, etc. The default is the digits (1 through 9, 0) then the lowercase and uppercase letters.

col

vector of colors. Colors are used cyclically.

cex

vector of character expansion sizes, used cyclically. This works as a multiple of par("cex"). NULL is equivalent to 1.0.

bg

vector of background (fill) colors for the open plot symbols given by pch = 21:25 as in points. The default NA corresponds to the one of the underlying function plot.xy.

xlab, ylab

titles for x and y axes, as in plot.

xlim, ylim

ranges of x and y axes, as in plot.

add

logical. If TRUE, plots are added to current one, using points and lines.

verbose

logical. If TRUE, write one line of what is done.

grid

logical; if TRUE, a background grid will be drawn

col.grid

grid color

col.acc

grid accent color


raredd/plotr documentation built on Nov. 19, 2023, 4:09 a.m.