I have performed PCA on my data set and found out that 95% of variability has been covered by the first three principal components. I wanted to perform a logistic regression on the data set. What do I do now?


Train the model as usual with those three components. We have to do the same thing on test data too. Your classification job can be done.

Note: By training a model with PCA components. You don't get feature importance. If that is fine, you can proceed with those three components. Else, those components can be useful for just visualization purpose.

| cite | improve this answer | |
  • $\begingroup$ any online resources to help me what I need to do step by step? $\endgroup$ – cgo Apr 7 at 0:57
  • 1
    $\begingroup$ I found this as most appropriate for your problem. This Explains step by step process of implementing PCA and finally used logistic regression for classification. Hope this helps. $\endgroup$ – Venkatesh Gandi Apr 7 at 4:49

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.