How to modify the property of the object output by fitensemble?

1 view (last 30 days)
Hi everyone,
I trained my data by fitensemble and obtained the output 'ens', which is an object. Because my data is large (more than hundreds of thousands), I want to remove the properties X, Y, W and UseObsForLearner so that it can substantially save my memory. Further, if I want the model constructed being used in my future intestigation, I can load it easily, quickly and without any memory required.
Any suggestions?
Thanks,
Best Regards,
Jorey

Accepted Answer

Shashank Prasanna
Shashank Prasanna on 6 Jun 2013
If you are using fitensemble to create a RegressionEnsemble or ClassificationEnsemble you can use the 'compact' function to remove the training data:
But of course since you throw out the training data you won't be able to do cross validation.

More Answers (0)

Tags

Community Treasure Hunt

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

Start Hunting!