biplotDAS {DASplusR} | R Documentation |
Generic function for producing a biplot on the current graphics device.
biplotDAS(x, ...) ## Default S3 method: biplotDAS(x, y, col, cex = rep(par("cex"), 2), pch = NULL, xlabs = NULL, ylabs = NULL, ylabs.nchar = NULL, arrow.len = 0.1, expand = 1, xlim = NULL, ylim = NULL, main = NULL, sub = NULL, xlab = NULL, ylab = NULL, ...) ## S3 method for class 'princomp': biplotDAS(x, choices = 1:2, ...) ## S3 method for class 'factanal': biplotDAS(x, choices = 1:2, ...)
x |
For biplot.default , the first set of points (a two-column
matrix), usually the scores computed in PCA or FA. For
biplot.princomp , an object of class "princomp" , and for
biplot.factanal , an object of class "factanal" . |
y |
The second set of points (a two-column matrix), usually the principal component or factor loadings. |
choices |
The numbers of the components or factors to be plotted, supplied as a vector of length two. |
col |
A vector of length two giving the colors for the first and second set of points (and the corresponding axes). If a single color is supplied, it is used for both sets. If it is missing and the default color is included in the palette, it will be used along with its subsequent color. Otherwise, the first two colors of the palette will be used. |
cex |
The character expansion factor to be used for labeling the two sets of points. Using different sizes for the two sets can be achieved by supplying a vector of length two. |
pch |
Plot character for the first set of points. It can be an integer
specifying a symbol or a single character. See points for
possible values and their interpretation. |
xlabs |
A vector of character strings to label the first set of
points. The default is to use the row names of x , or
1:n if the row names are NULL . If supplied, this is used
rather than pch . |
ylabs |
A vector of character strings to label the second set of
points. The default is to use the row names of y , or
1:n if the row names are NULL . |
ylabs.nchar |
An integer giving maximum number of characters to be
used for labeling the second set of points. Longer character strings
are truncated. This is ignored unless ylabs is missing and the
row names of y are used as labels. |
arrow.len |
The length of the arrow heads on the arrows representing
the second set of points. The arrow head can be suppressed by supplying
arrow.len = 0 . |
expand |
An expansion factor to be applied when plotting the second set of points relative to the first. This can be used to tweak the scaling of the two sets to a physically comparable scale. |
xlim, ylim |
Limits for the x- and y- axes in the units of the first set of points. |
main, sub, xlab, ylab |
Plot annotation. |
... |
Additional graphical parameters or optional arguments to be
passed to biplot.default . |
A biplot aims to represent both the observations and the variables of a matrix of multivariate data on the same plot. Note that there are many variations on biplots.
The function biplotDAS.default
merely provides the underlying code
to plot observations and variables on the same figure.
Graphical parameters can also be given to biplotDAS
, e.g., the
size of pch
, xlabs
and ylabs
is controlled by
cex
.
A plot is produced on the current graphics device.
Andreas Alfons <andreas.alfons@student.tuwien.ac.at>
Gabriel, K.R. (1971) The biplot graphical display of matrices with application to principal component analysis. Biometrika, 58, 453–467.
Reimann, C., Filzmoser, P., Garrett, R.G. and Dutter, R. (2008) Statistical Data Analysis Explained. Wiley & Sons.
BiplotMain
, princompDAS
, factanalDAS
.
## KOLA95_Moss data data(KOLA95_MOSS) princomp.obj <- princompDAS(data = KOLA95_MOSS, vars = c("Cu","Mg","Mn","Ni","Rb","Th"), logVars = c("Cu","Mg","Mn","Ni","Rb","Th"), cor = TRUE, robust = "covMcd") biplotDAS(princomp.obj, pch = "+")