Learn R Programming

ade4 (version 1.2-2)

within.pca: Normed within Principal Component Analysis

Description

performs a normed within principal component analysis.

Usage

within.pca(df, fac, scaling = c("partial", "total"), 
    scannf = TRUE, nf = 2)

Arguments

df
a data frame with quantitative variables
fac
a factor distributing the rows of df in classes
scaling
a string of characters as a scaling option : if "partial", for each factor level, the sub-array is centred and normed. If "total", for each factor level, the sub-array is centred and the total array is then normed.
scannf
a logical value indicating whether the eigenvalues bar plot should be displayed
nf
if scannf FALSE, an integer indicating the number of kept axes

Value

  • returns a list of the sub-class within of class dudi'. See within

References

Bouroche, J. M. (1975) Analyse des donn�es ternaires: la double analyse en composantes principales. Th�se de 3�me cycle, Universit� de Paris VI.

Examples

Run this code
data(meaudret)
wit1 <- within.pca(meaudret$mil, meaudret$plan$dat, 
    scan = FALSE, scal = "partial")
kta1 <- ktab.within(wit1, colnames = rep(c("S1","S2","S3","S4","S5"), 4))
unclass(kta1)
# See pta
plot(wit1)

Run the code above in your browser using DataLab