-
-
Notifications
You must be signed in to change notification settings - Fork 26k
Add title to DecisionBoundaryDisplay #31558
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Thanks for making this PR and starting to tackle the issue! What do you think about using the newly stored attributes in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @ansamz !
Here are some thoughts. Also I wonder if the title could be something like:
'DecisionTreeClassifier ("predict" method)' or
'DecisionTreeClassifier using "predict" method'
?
if estimator_name_to_display or response_method_to_display: | ||
ax.set_title( | ||
f"Boundary: {estimator_name_to_display} " | ||
f"Method: {response_method_to_display}" | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure about this logic. Do we want to add a title if only response_method_to_display
is provided?
If we did, we'd have to change the title to e.g., 'Method: predict', or '"predict" method'
Also CI is failing, as you need to include the extra parameters in the class docstring. |
Hello,
Reference Issues/PRs
#27462 (partially)
What does this implement/fix? Explain your changes.
I tackled this part of StefanieSenger's request
add a title to the plot that clearly states which response_method from which estimator was used in the plot
what I did was save the response method and estimator in a variable in order to add them to the plot
and then using the set_title() mthod from matplotlib we can add the title to the plots.
Any other comments?
This is how I tested it on the iris dataset (not sure if this is the best approach to solving the issue)
@betatim @glemaitre