Learn R Programming

RVAideMemoire (version 0.9-35)

plot1comp.ind: Plot of indiviuals and their class on a single axis (component)

Description

Represent indivual points on a single axis (usually a factorial component) and add their class, respecting to a given factor.

Usage

plot1comp.ind(dfxy, fac, axis = 1, col = 1:nlevels(fac), cex = 1, box = TRUE)

Arguments

dfxy
a data frame containing coordinates of individuals on the axi(e)s.
fac
a factor giving the class of each individual.
axis
axis to be represented (the first by default).
col
a vector of colors (one value per class of the factor).
cex
size of class names.
box
logical, should a box to be drawn around class names?

See Also

s.class

Examples

Run this code
require(MASS)
data(iris)
LDA <- lda(iris[,1:4],iris$Species)
LDA.form <- LDA.format(LDA)
plot1comp.ind(LDA.form$li,LDA.form$grouping,col=1:3)

Run the code above in your browser using DataLab