How to use the outputs of the Stepwise function?

2 vues (au cours des 30 derniers jours)
John Doe
John Doe le 22 Déc 2011
Hello, I am classifying P300 responses using matlab and all the papers recommed Stepwise Linear Discriminant Analysis. I have inputted training data using Stepwise(X,y) and gotten a result with a high R-square value, but when I hit export I don't know what variables I need and how I would apply them to new data to classify it.

Réponses (1)

Richard Willey
Richard Willey le 22 Déc 2011
Hi John
The stepwise function in Statistics Toolbox is used for liner regression.
If you want to use a stepwise type algorithm with linear discriminant analysis your best option is to wrap the sequentialfs function around "classify" (Classify implement linear discriminant analysis).
sequentialfs will output a mask that you can use to indicate which variables should/should not be included in your final model.

Catégories

En savoir plus sur Statistics and Machine Learning Toolbox dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by