Principal component analysis

Principal component analysis (PCA) projects data onto new orthogonal axes, the principal components, ranked by decreasing explained variance. It reduces the number of dimensions while keeping as much information as possible, and is used to visualize or decorrelate. Variables must be standardized.

Example

PCA(n_components=2).fit_transform(X_s)

Related concepts

The whole glossary