Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

nipals

PCA calculation with the NIPALS algorithm


Description

NIPALS is an algorithm for computing PCA scores and loadings.

Usage

nipals(X, a, it = 10, tol = 1e-04)

Arguments

X

numeric data frame or matrix

a

maximum number of principal components to be computed

it

maximum number of iterations

tol

tolerance limit for convergence of the algorithm

Details

The NIPALS algorithm is well-known in chemometrics. It is an algorithm for computing PCA scores and loadings. The advantage is that the components are computed one after the other, and one could stop at a desired number of components.

Value

T

matrix with the PCA scores

P

matrix with the PCA loadings

Author(s)

Peter Filzmoser <P.Filzmoser@tuwien.ac.at>

References

K. Varmuza and P. Filzmoser: Introduction to Multivariate Statistical Analysis in Chemometrics. CRC Press, Boca Raton, FL, 2009.

See Also

Examples

data(glass)
res <- nipals(glass,a=2)

chemometrics

Multivariate Statistical Analysis in Chemometrics

v1.4.2
GPL (>= 3)
Authors
Peter Filzmoser and Kurt Varmuza
Initial release
2017-03-17

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.