Click or drag to place points. Try making an elongated cloud — PCA finds the direction of greatest spread.
feature space
NOISE LEVEL medium
PRESETS
0
Points
—
Corr. r
Add at least 10 points, or use a preset above.
Step 02
PCA finds the axes of maximum variance
PC1 points in the direction the data spreads most. PC2 is perpendicular to PC1.
principal component axes
VARIANCE EXPLAINED
PC1
PC2
Data
—
Step 03
Project onto fewer dimensions
Reduce from 2 components to 1. Red lines show reconstruction error — the information lost in compression.
projection
COMPONENTS KEPT 2
INFORMATION
100%
Kept
0%
Lost
Original
Projected
Error
Use 2 components to keep all information.
Step 04
Why StandardScaler matters
Two correlated variables with different units. Drag the slider to change the scale ratio — watch PCA get misled, then fix it with standardisation.
SCALE RATIO (X : Y)
1× (equal)
1× (equal scale)← drag to increase ratio →64× (huge difference)
✕ Without scaling
✓ With StandardScaler
VARIANCE — RAW
VARIANCE — SCALED
At equal scales, raw and scaled PCA are identical — PC1 captures the real correlation. Drag the slider right to see what happens as the scales diverge.