msPCA: An R Package for Sparse PCA with Multiple Components

2026-07-06Machine Learning

Machine Learning
AI summary

The authors developed msPCA, a free R package that finds important patterns in large datasets by focusing only on a small number of features. Their method creates multiple sparse principal components, which means each pattern uses only a few variables, making it easier to understand. The algorithm ensures these components capture lots of information without overlapping too much, based on two different ways to reduce redundancy. Tests show msPCA works efficiently even with thousands of variables, balancing speed and accuracy well.

principal component analysissparse PCAloading vectorsvariance explainedorthogonalitycorrelationdimensionality reductionR packagealternating maximization
Authors
Ryan Cory-Wright, Jean Pauphilet
Abstract
We present msPCA: an open-source R package for sparse principal component analysis with multiple components. It implements an alternating maximization algorithm to generate a set of sparse loading vectors that collectively explain a large fraction of the variance in a dataset, while remaining non-redundant. The algorithm supports two definitions of non-redundancy: either orthogonality of the loading vectors or zero pairwise correlation between principal components (PCs). In the reported benchmarks, msPCA solves sparse PCA problems with thousands of features, achieving competitive runtimes while producing sparse components with controlled feasibility violations and a high fraction of variance explained.