Last data update: 2014.03.03

R: Plot confidence ellipses
plotellipseR Documentation

Plot confidence ellipses

Description

Plot confidence ellipses.

Usage

plotellipse(mat, alpha = 0.05, coord = c(1,2), eig, cex = 1, 
    color = NULL, title = NULL)

Arguments

mat

Matrix with all the points

alpha

the confidence level of the ellipses

coord

a length 2 vector specifying the components to plot

eig

a matrix with the component of the factor analysis (in row) and the eigenvalues, the inertia and the cumulative inertia for each component. Typically, the eig output of the construct.axes function

cex

cf. function par in the graphics package

color

a vector with the colors used; by default there are 35 colors defined

title

string corresponding to the title of the graph you draw (by default NULL and a title is chosen)

Author(s)

Francois Husson

Examples

## Not run: 
data(chocolates)
donnee <- cbind.data.frame(sensochoc[,c(1,4,5:18)])
axe <- construct.axes(donnee, scale.unit = TRUE)
simul <- simulation(axe)
plotellipse (simul, alpha = 0.05, eig = signif(axe$eig,4))
#######################################
donnee <- cbind.data.frame(sensochoc[,c(1,4,5:18)])
axe <- construct.axes(donnee, group = c(6,8), 
    name.group = c("A-F","T-S"),scale.unit = TRUE)
simul <- simulation(axe, nbgroup = (ncol(axe$partiel)-2)/(ncol(axe$moyen)-2))
plotellipse (simul, alpha = 0.05, eig = signif(axe$eig,4))

## End(Not run)

Results