cleaning & added pca_dir