title: selection of features using PCA
body: <p>I am doing unsupervised classification. For this I have 8 features (Variance of Green, Std. div. of Green , Mean of Red, Variance of Red, Std. div. of Red, Mean of Hue, Variance of Hue, Std. div. of Hue) for classification per image and I want to select 3 most significant features using PCA. I have written the following code for feature selection
  (where dimension of feature is : 179X8) :</p>
  
  <pre><code>for c=1:size(feature,1)
     feature(c,:)=feature(c,:)-mean(feature)
  end
  
  DataCov=cov(feature); % covariance matrix
  [PC,variance,explained] = pcacov(DataCov)
  </code></pre>
  
  <p>This gives me : </p>
  
  <p>PC =</p>
  
  <pre><code>0.0038   -0.0114    0.0517    0.0593    0.0039    0.3998    0.9085   -0.0922
  0.0755   -0.1275    0.6339    0.6824   -0.3241   -0.0377   -0.0641    0.0052
  0.7008    0.7113   -0.0040    0.0496   -0.0207    0.0042    0.0012    0.0002
  0.0007   -0.0012    0.0051    0.0101    0.0272    0.0288    0.0873    0.9953
  0.0320   -0.0236    0.1521    0.2947    0.9416   -0.0142   -0.0289   -0.0266
  0.7065   -0.6907   -0.1282   -0.0851    0.0060    0.0003    0.0010   -0.0001
  0.0026   -0.0037    0.0632   -0.0446    0.0053    0.9125   -0.4015    0.0088
  0.0543   -0.0006    0.7429   -0.6574    0.0838   -0.0705    0.0311   -0.0001
  </code></pre>
  
  <p>variance =</p>
  
  <pre><code>0.0179
  0.0008
  0.0001
  0.0000
  0.0000
  0.0000
  0.0000
  0.0000
  </code></pre>
  
  <p>explained =</p>
  
  <pre><code>94.9471
  4.1346
  0.6616
  0.2358
  0.0204
  0.0003
  0.0002
  0.0000
  </code></pre>
  
  <p>This means first  principle component has 94.9% variance explained and so on ... but these are in order of  most to least significant. 
  How can I know which features (from 1 to 8) to be selected based on above information.</p>