Learn R Programming

corregp (version 0.1.2)

pcplot.corregp: Parallel Coordinate Plotting for Correspondence Regression

Description

Method to produce a parallel coordinate plot of the output of a correspondence regression.

Usage

## S3 method for class 'corregp':
pcplot(x, parm = "x", axes, add_ci = FALSE, cl = 0.95,
  nq = TRUE, col = "darkgrey", cex = par("cex"), font = par("font"),
  lwd = par("lwd"), lty = par("lty"), lcol = col, psym = NULL,
  pcol = col, pcex = cex, ecol = "red", ewid = 1, etyp = 2,
  acol = "black", awid = 1, atyp = 1, acex = cex, afnt = font,
  adir = 1, add_scale = FALSE, main = NULL, sub = NULL, ...)

pcplot(x, ...)

Arguments

x
The output of a call to corregp (i.e. an object of class "corregp").
parm
The parameter for which to plot the coordinates. Can be either "y", "x", or any vector of term names in X, level names in X or level names in Y. Defaults to "x".
axes
The axes to plot.
add_ci
Logical specifying whether to include the confidence intervals. Defaults to FALSE.
cl
The confidence level for the confidence intervals. Defaults to 0.95.
nq
Logical specifying whether to use a normal quantile (i.e. apply qnorm) in the computation of the confidence intervals. Defaults to TRUE. If FALSE, then the confidence intervals
col
Color of the text labels: either numeric or see colors.
cex
Character expansion factor: a number to specify the size of the text labels.
font
Font of the text labels: 1 for plain, 2 for bold, 3 for italic, and 4 for bold italic. Defaults to 1.
lwd
Width of the connecting lines: a number to specify the line width.
lty
Line type of the connecting lines: 0 or "blank", 1 or "solid", 2 or "dashed", 3 or "dotted", 4 or "dotdash", 5
lcol
Color of the connecting lines: either numeric or see colors.
psym
The symbol (or "plotting character") for the values of the coordinates on the axes.
pcol
Color of the symbol for the values on the axes: either numeric or see colors.
pcex
Character expansion factor of the symbol for the values on the axes.
ecol
Color of the error lines (connecting the confidence intervals on each axis): either numeric or see colors.
ewid
Width of the error lines (connecting the confidence intervals on each axis): a number to specify the line width.
etyp
Line type of the error lines (connecting the confidence intervals on each axis): 0 or "blank", 1 or "solid", 2 or "dashed", 3 or "dotted", 4
acol
Color of the parallel axes: either numeric or see colors.
awid
Width of the parallel axes: a number to specify the line width.
atyp
Line type of the parallel axes: 0 or "blank", 1 or "solid", 2 or "dashed", 3 or "dotted", 4 or "dotdash", 5 or
acex
Character expansion factor for the labels of the parallel axes.
afnt
Font for the labels of the parallel axes: 1 for plain, 2 for bold, 3 for italic, and 4 for bold italic.
adir
Reading direction of the labels on the parallel axes: either a numeric value between 0 and 3 (see the las argument in the graphical parameters par) o
add_scale
Logical specifying whether to add a scale for the parallel axes (which are normalised).
main
The main title of the plot.
sub
The subtitle of the plot.
...
Further arguments passed to or from other methods.

Value

  • A parallel coordinate plot containing the output of a correspondence regression.

Details

Although adding lines for confidence intervals is possible, it is not recommended, as it typically leads to an unreadable plot.

See Also

ciplot.corregp, plot.corregp.

Examples

Run this code
data(HairEye)
haireye.crg <- corregp(Eye ~ Hair * Sex, data = HairEye, b = 3000)
pcplot(haireye.crg, parm = "y", axes = 1:3)
pcplot(haireye.crg, parm = c("Hair", "Sex"), axes = 1:3)

Run the code above in your browser using DataLab