Learn R Programming

sprm (version 1.2.2)

biplot.prmda: Biplot for prmda objects of PRM discriminant analysis

Description

This biplot for prmda objects visualizes the original variables which contribute to the model and their impact on the latent components as well as the position of the observations in the transformed space. The data is projected onto two of the latent components and colored according to class membership.

Usage

"biplot"(x, comps = c(1, 2), colors = list(scores1="orange", scores2="darkgreen", loadings="red", background="gray84"), textsize = 6, arrowshapes = c(25, 0.03), labelpos = 0.35, ...)

Arguments

x
object of class prmda.
comps
vector with two integers, referring to the components to be plotted.
colors
list of four elements named scores1 (for observations of group coded with 1), scores2 (for observations of group coded with -1), loadings and background with color codes or names of colors.
textsize
the text size in which to print the scores and loading names.
arrowshapes
vector of length two containing the angle of the arrowheads and their relative length in npc.
labelpos
numeric value; determines distance of the arrow label to the arrowhead.
...
further arguments. Currently not used.

References

Hoffmann, I., Filzmoser, P., Serneels, S., Varmuza, K., Sparse and robust PLS for binary classification.

See Also

prmda

Examples

Run this code
data(iris)
data <- droplevels(subset(iris,iris$Species!="setosa"))
mod <- prmda(Species~.,data, a=2, class="lda")
biplot(mod)

Run the code above in your browser using DataLab