Does this mean that my trees are grown too deep? Or can this be an indicator of perfect classification with probability of 100% or 0%?
Random forest prediction probabilities
12 ビュー (過去 30 日間)
古いコメントを表示
Hi,
I trained a random forest model using MATLAB's "TreeBagger" function. However, when I use the "predict" function, my probabilities are all 0 or 1 except for a few predictions. Despite having 4000 observations, my roc curve has also only three data point. Can you suggest any solution for this problem?
Thanks in advance.
4 件のコメント
採用された回答
Aditya Patil
2021 年 5 月 10 日
Getting a probability of 1 suggests that the model has overfitted, and the observation is being predicted as belonging to the specific class by all trees.
You can overcome this issue by reducing the size of the trees. Few of the options that might help are,
- MinLeafSize: Set this to higher value
- MaxNumSplits: Set this to a lower value
Alternately, you may want to use a different approach entirely, by using SVMs or other classifiers.
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Classification Ensembles についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!