Implement real PCA (with dimensionality reduction).