Skip to content

DOC add link to plot_iris_dtc example in DecisionTreeClassifier documentation - #30650

Closed
Crucible0 wants to merge 1 commit into
scikit-learn:mainfrom
Crucible0:plot-iris-dtc
Closed

Crucible0 wants to merge 1 commit into
scikit-learn:mainfrom
Crucible0:plot-iris-dtc

Conversation

@Crucible0

Copy link
Copy Markdown

This pull request adds a reference link to the plot_iris_dtc.py example in the documentation for DecisionTreeClassifier.

Changes:

  • Added a link to plot_iris_dtc.py in the DecisionTreeClassifier API docstring to give an example.

Purpose:

  • To make it easier for users to discover examples relevant to DecisionTreeClassifier.

Related Issue:

Towards #30621.

@github-actions

Copy link
Copy Markdown

✔️ Linting Passed

All linting checks passed. Your pull request is in excellent shape! ☀️

Generated for commit: 0d4daf6. Link to the linter CI: here

@virchan virchan left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR @Crucible0! I have a few comments.

It might be a good idea to include the example in the plot_tree documentation as well.

@Crucible0

Copy link
Copy Markdown
Author

Thank you for the PR @Crucible0! I have a few comments.

It might be a good idea to include the example in the plot_tree documentation as well.

Thank you for the feedback! I'll include the example in the plot_tree documentation and update the pull request shortly.

Comment thread sklearn/tree/_classes.py
0.93..., 0.93..., 1. , 0.93..., 1. ])

See :ref:`sphx_glr_auto_examples_tree_plot_iris_dtc.py` for an
example of training and visualizing a decision tree classifer on

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi. I believe you mean classifier (missing an "i").

@adrinjalali

Copy link
Copy Markdown
Member

I actually think this particular file is referenced enough in the tree.rst file and not sure if we need to link it from the docstring as well. So I'm leaning towards closing this one, and you can probably remove it from your list @StefanieSenger .

Sorry about this @Crucible0 , it's not trivial as which examples really need to be added in different places, and sometimes we don't actually need more links.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants