PCA bug partially solved