2
$\begingroup$

I have a data set with 60000 rows and 32 columns. I want to use SVM (with some more constraints that make it more complicated)and I think 32 columns are too large. So I decided to use PCA. But when I load PCA, the first 20 component describe 85% of data which 20 variables still is too large I think, but it is better than 32.
I am wondering is that ok if I use PCA? when n>>m? if not what is a better option?

$\endgroup$
  • $\begingroup$ Why is 32 columns "large"? Even by (extremely sketchy) rules of thumb, you have a ratio of 1875 observations to one variable. That is more than reasonable IMO. What I would recommend: try PCA, keep how ever many components you think is reasonable, and validate your model properly. If there is improvement over not using PCA, go with PCA. You can even set the number of components to retain as a tuning parameter itself (pick number of components to whatever validates the best), or retain the PCA variables + original columns as well and fit a regular SVM on the combined dataset. $\endgroup$ – aranglol Jul 8 '19 at 23:29
  • $\begingroup$ I would further advise that the cost parameter in your SVM is crucial and can (usually) adequately control the "complexity" of the fitted boundary. You may not need to do any feature extraction/selection; in fact it might make your model worse. $\endgroup$ – aranglol Jul 8 '19 at 23:36
2
$\begingroup$

If you can, go for some non-linear dimensionality reduction technique. The most powerful are Autoencoders, but you can also use t-SNE or other manifold techniques.

The problem of PCA is that it can extract only latent factors that are linearly associated with your variables. Using non-linear techniques, less variables can let you capture more of the original variance.

| improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.