Website: predict function with sPLS-DA unclear

Create issue
Issue #2 resolved
Kim-Anh Le Cao repo owner created an issue

email from: Stephan Kolassa, date: 27/03

Hi,

I am attempting to predict from a plsda model. I have a classification into 2 classes, and I ran plsda() with ncomp=3. The newdata contains 8 cases. So predict(model,newdata)$predict is an 8x2x3 array, where the 3rd dimension corresponds to the 3 model components.

How do I extract the class predictions for my 8 cases? Do I average across the 3rd dimension? Or something else?

I read the FAQ, which pointed me to this page: http://perso.math.univ-toulouse.fr/mixomics/methods/spls-da/ but the assignments to test.predict there do not enlighten me... nor the example case. And unfortunately, I don't have access to the textbook by Tenenhaus, although the French would not be a problem.

Any pointers would be very much appreciated. Thank you!

Best Stephan

Comments (2)

  1. Log in to comment