How can I specify a Min LeafSize in a decision tree and also optimize it?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Rafael Cordero
am 22 Jul. 2021
Kommentiert: Rafael Cordero
am 23 Jul. 2021
Hello all,
I was wondering if it is possible to optimize the decision tree hyperparameter of MinLeafSize whilst imposing a limit on this MinLeafSize.
I.e.: I would like to optimize the MinLeafSize parameter, but I dont want it to be smaller than e.g. 50. Is this possible?
Thank you
0 Kommentare
Akzeptierte Antwort
Alan Weiss
am 23 Jul. 2021
Take a look at the hyperparameter optimization argument of fitctree. You can fit the MinLeafSize parameter. To set the range you want, as the documentation states, "Set nondefault parameters by passing a vector of optimizableVariable objects that have nondefault values." Follow the example.
Alan Weiss
MATLAB mathematical toolbox documentation
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Problem-Based Optimization Setup finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!