PCAcv: Principal Component Analysis cross-validation error

Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/PCAcv.R

Description

PRESS values for PCA as implemented by Eigenvector and described by Bro et al. (2008).

Usage

1
PCAcv(X, ncomp)

Arguments

X

matrix object to perform PCA on.

ncomp

integer number of components.

Details

For each number of components predicted residual sum of squares are calculated based on leave-one-out cross-validation. The implementation ensures no over-fitting or information bleeding.

Value

A vector of PRESS-values.

Author(s)

Kristian Hovde Liland

References

R. Bro, K. Kjeldahl, A.K. Smilde, H.A.L. Kiers, Cross-validation of component models: A critical look at current methods. Anal Bioanal Chem (2008) 390: 1241-1251.

See Also

plot.SMI (print.SMI/summary.SMI), RV (RV2/RVadj), r1 (r2/r3/r4/GCD), allCorrelations (matrix correlation comparison).

Examples

1
2
X1  <- scale( matrix( rnorm(100*300), 100,300), scale = FALSE)
PCAcv(X1,10)

MatrixCorrelation documentation built on Sept. 25, 2017, 1:04 a.m.