improved pca extraction with smoothing