Added link to plot_adaboost_multiclass.py example#27913
Added link to plot_adaboost_multiclass.py example#27913adrinjalali merged 21 commits intoscikit-learn:mainfrom
Conversation
in _weight_boosting.py.
|
Hello @marenwestermann, Thank you for the reference, it's really helpful. I've moved the example link from the example itself to the doc string in |
sklearn/ensemble/_weight_boosting.py
Outdated
|
|
||
| Read more in the :ref:`User Guide <adaboost>`. | ||
|
|
||
| For more example of usage, see |
There was a problem hiding this comment.
It's better to put the reference under the "Examples" section and write something like
For an example of how AdaBoost is used to fit a sequence of Decision Trees, refer to :ref:`sphx_glr_auto_examples_ensemble_plot_adaboost_multiclass.py`.
It would also be good to leave a reference in the doc string of the DecisionTreeClassifier estimator under the "Notes" or "Examples" section.
There was a problem hiding this comment.
Thank you for writing back!
The following files are modified:
ensemble\_weight_boosting.py: Reworked the example reference and moved it below the Example section.
tree\_classes.py: Added the example reference of using AdaBoost with decision trees for the DecisionTree class.
Please let me know if you need anything else.
`ensemble/_weight_boosting.py` file, moving it below the `Examples` section for improved organization. Included an AdaBoost example reference within the DecisionTree class in the `tree/-class.py` file.
There was a problem hiding this comment.
Apologies for the belated reply. I added a small comment (see below). Additionally it would be good to add a link to the example to this section of the user guide which you can find in the code here. Just add the link to this example to the examples that are already listed there.
sklearn/ensemble/_weight_boosting.py
Outdated
| >>> clf.score(X, y) | ||
| 0.96... | ||
|
|
||
| For an example of using AdaBoost to fit a sequence of DecisionTrees as weak learners, |
There was a problem hiding this comment.
I just realised that if estimator=None as is the case here, the base estimator is DecisionTreeClassifier. So it would be better to write For a detailed example ... .
…sion Trees user guide. - Modified the doc-string wording in the `AdaBoostClassifier` class referencing to the aforementioned example.
|
Thank you for the reply. I have updated the following files:
Please let me know if I missed anything. |
|
Thank you for the update @virchan. Can you fix the linting issue? When you click on the details under "ci/circleci: lint" in the code checks you'll see the error messages. |
|
Thank you for the follow-up! The linting issue is fixed, all checks have passed. |
| For a detailed example of using AdaBoost to fit a sequence of DecisionTrees | ||
| as weaklearners, please refer to | ||
| :ref:`sphx_glr_auto_examples_ensemble_plot_adaboost_multiclass.py`. |
There was a problem hiding this comment.
I think this is the only place where the mention makes sense. I would then remove the other two mentions in this PR.
|
Hello, Thank you for the feedback! The example references are removed from the Please let me know if there is anything else. |
Reference Issues/PRs
Towards #26927
What does this implement/fix? Explain your changes.
Includes a link to the
plot_adaboost_multiclass.pyexampleAny other comments?
NA