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

Skip to content

[DOC]: Add grid to style sheets #23730

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

Closed
wants to merge 3 commits into from

Conversation

Kinza-Raza
Copy link

PR Summary

This PR adds gridlines for all available style sheets to help visualise the default colour of the grid in each style sheet.
Addresses #23601

PR Checklist

Tests and Styling

  • Has pytest style unit tests (and pytest passes).
  • [N/A] Is Flake 8 compliant (install flake8-docstrings and run flake8 --docstring-convention=all).

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Thank you for opening your first PR into Matplotlib!

If you have not heard from us in a while, please feel free to ping @matplotlib/developers or anyone who has commented on the PR. Most of our reviewers are volunteers and sometimes things fall through the cracks.

You can also join us on gitter for real-time discussion.

For details on testing, writing docs, and our review process, please see the developer guide

We strive to be a welcoming and open project. Please follow our Code of Conduct.

@jklymak
Copy link
Member

jklymak commented Aug 25, 2022

This is probably an acceptable solution, but you need some way of telling users the one out of six panels is not actually the default. Clearest would likely be to add a small annotation on the plot with the changed default.

@Kinza-Raza
Copy link
Author

You're right @jklymak , we're building consensus on #23601 on how to proceed. I'll make the changes accordingly.

@timhoffm
Copy link
Member

If we want to add a plot with a grid (of which I'm still not convinced that it's necessary)., that'd need to be clearly separated. E.g. by a vertical line.

Mockup:

image

This means we have to free one Axes for this illustration. I think the lines should be in the regular part. We might get rid / reuse the colored circles for this. It's not a standard plot and does not really show something new: The color cycling is already present in the lines plot and a scatter-like picture is already included through the scatter() function.

@jklymak
Copy link
Member

jklymak commented Aug 26, 2022

I was suggesting just annotating the line plots with a ax.grid(True) so its clear that was used for those plots.

@Kinza-Raza
Copy link
Author

@timhoffm does this work or we could go with the approach you suggested

Preview:
Screenshot 2022-08-27 at 8 37 07 PM

@timhoffm
Copy link
Member

timhoffm commented Sep 8, 2022

I'm still very skeptical whether adding the grid is an improvement.

  • Plus: You show what the style would look like if the grid was activate.
  • Minus: You dilute the impression with a grid-on plot that is not the pure style. It is very hard to communicate that visually.

I'd rather not go down this road. But if others really want this I suggest something very explicit like:

grafik

The content of the grid example could be different if you like, I have no strong opinion here.

@story645
Copy link
Member

@Kinza-Raza sorry this fell off the radar - do you have the bandwidth to follow up on Tim's suggestion?

@kostyafarber
Copy link
Contributor

@story645 Might take a look at this one?

@story645
Copy link
Member

That's ok w/ me if you credit @Kinza-Raza as a co-author.

@Kinza-Raza
Copy link
Author

Feel free to take this up @kostyafarber

@kostyafarber
Copy link
Contributor

Opened a PR at #24020.

@story645
Copy link
Member

story645 commented Oct 2, 2022

closed since #24020 went in, but I'm a little iffy if the co-authoring was done properly. Thank you @Kinza-Raza for all the work you did on this!

@kostyafarber
Copy link
Contributor

closed since #24020 went in, but I'm a little iffy if the co-authoring was done properly. Thank you @Kinza-Raza for all the work you did on this!

@Kinza-Raza Thank you for your work! Sorry if I didn't attribute you properly.

@story645
Copy link
Member

story645 commented Oct 2, 2022

Is my fault for not aggressively flagging it, but I think we can amend the commit if we get the right name/email combo @QuLogic?

@jklymak
Copy link
Member

jklymak commented Oct 2, 2022

Why do you think the co-authorship is wrong on the commit? fd5cf5c

@jklymak jklymak closed this Oct 2, 2022
@story645
Copy link
Member

story645 commented Oct 2, 2022

B/c @Kinza-Raza avatar isn't showing up as a co-author so I think that means it's not linking to her account.

@kostyafarber
Copy link
Contributor

Yeah I made sure to check one of her commits and get the correct email. But she might of changed it since then. Not sure.

@Kinza-Raza
Copy link
Author

Not sure why my work email showed up. The correct one is [email protected].

@jklymak
Copy link
Member

jklymak commented Oct 2, 2022

You may have your work email in your .gitconfig

@QuLogic QuLogic added this to the v3.7.0 milestone Oct 4, 2022
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.

[Doc]: add gridlines to style sheet reference
8 participants