Skip to contents

Perform bootstrap resampling for Principal Component Analysis (PCA) to estimate component and score variability.

Usage

# S3 method for pca
bootstrap(x, nboot = 100, k = ncomp(x), ...)

Arguments

x

A fitted PCA model object.

nboot

The number of bootstrap resamples (default: 100).

k

The number of components to bootstrap (default: all components in the fitted PCA model).

...

Additional arguments to be passed to the specific model implementation of bootstrap.

Value

A list containing bootstrap z-scores for the loadings (zboot_loadings) and scores (zboot_scores).

References

Fisher, Aaron, Brian Caffo, Brian Schwartz, and Vadim Zipunnikov. 2016. "Fast, Exact Bootstrap Principal Component Analysis for P > 1 Million." Journal of the American Statistical Association 111 (514): 846-60.

Examples

X <- matrix(rnorm(10*100), 10, 100)
x <- pca(X, ncomp=9)
bootstrap_results <- bootstrap(x)