Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@faizanhuda12
Copy link

@faizanhuda12 faizanhuda12 commented Nov 13, 2025

Corrected two instances where AGE and EXPERIENCE coefficients were plotted in the wrong order.
This aligns the scatter plots with the axis labels and fixes the inconsistency raised in Issue #32706.

Reference Issues/PRs

Fixes #32706

What does this implement/fix? Explain your changes.

This PR updates two plt.scatter() calls in the linear model coefficient interpretation example where
AGE and EXPERIENCE were plotted in the wrong order.

According to the axis labeling (Experience on the x-axis and Age on the y-axis), the arguments to
plt.scatter() needed to be swapped. Both plots have now been corrected for consistency.

Any other comments?

The modification affects only example documentation code and does not change any library behavior.

…n#32706)

Corrected two instances where AGE and EXPERIENCE coefficients were plotted in the wrong order.
This aligns the scatter plots with the axis labels and fixes the inconsistency raised in Issue scikit-learn#32706.
@github-actions
Copy link

github-actions bot commented Nov 13, 2025

✔️ Linting Passed

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

Generated for commit: 40f53c5. Link to the linter CI: here

Copy link
Member

@ArturoAmorQ ArturoAmorQ left a comment

Choose a reason for hiding this comment

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

Hi @faizanhuda12, thanks for addressing this issue. Maybe I am just being a bit nitpicky here, but for me it would make more sense to just swap xlim <-> ylim. What do you think?

@ArturoAmorQ ArturoAmorQ changed the title Fix swapped axes in linear model coefficient plots (Issue #32706) Doc Fix swapped axes in linear model coefficient plots (Issue #32706) Nov 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Axes labels of graphs switched at Line 396 & 632

2 participants