Clear Filters
Clear Filters

Principle Component Analysis

2 views (last 30 days)
Tim Micallef
Tim Micallef on 28 Mar 2011
I'm performing PCA on a sample from my dataset (using princomp) containing 5 attributes and 20,000 values for each attribute. I then want to classify the remainder of the dataset having taken out the least important attributes. Using PCA is it possible, using the ouputs that princomp provides, to remove one or two of the attributes that are less important for classification purposes? Or does PCA not even provide this information?

Accepted Answer

Andrew Newell
Andrew Newell on 28 Mar 2011
If your data are in the matrix X and ndim is the number of attributes you want to retain, then you can use
[residuals,reconstructed] = pcares(X,ndim);
then reconstructed is what you want.

More Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!