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

Skip to content

Sort named colors example vertically for easier comparison of similar colors #11658

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

Merged
merged 3 commits into from
Jul 15, 2018

Conversation

joelostblom
Copy link
Contributor

@joelostblom joelostblom commented Jul 14, 2018

PR Summary

Just a suggestion to sort the named colors example vertically in order to place similar colors closer together which can facilitate comparisons. Also changed spacing and the size of the color lines relative the text.

Old appearance

image

New appearance

image

PR Checklist

  • Has Pytest style unit tests
  • Code is PEP 8 compliant
  • New features are documented, with examples if plot related
  • Documentation is sphinx and numpydoc compliant
  • Added an entry to doc/users/next_whats_new/ if major new feature (follow instructions in README.rst there)
  • Documented in doc/api/api_changes.rst if API changed in a backward-incompatible way


fig, ax = plt.subplots(figsize=(8, 5))
fig, ax = plt.subplots(figsize=(12, 10))

Choose a reason for hiding this comment

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

Note that no image on the page should be larger than 900 pixels in width (=9 inch @ the default 100dpi). Otherwise the image will overlap (or be downsampled).

Otherwise this is a great idea! 👍

@ImportanceOfBeingErnest
Copy link
Member

This is how the image looks like in the docs:

image

Did you use rcParams different from the default ones when designing this?

@joelostblom
Copy link
Contributor Author

@ImportanceOfBeingErnest Sorry about that, I was plotting in the Jupyter Notebook initially. When I plotted outside the notebook, I noticed the same overlap as in the image you sent. After my latest commit it looks like this for me outside the notebook:

image

Thanks for the note on the figure size also!

@ImportanceOfBeingErnest
Copy link
Member

This looks very nice now. 🎉

The error in the LGTM analysis seems to be unrelated to this PR, it appears on other recent PRs as well.

@jklymak jklymak added this to the v2.2-doc milestone Jul 15, 2018
@jklymak jklymak merged commit c1d086f into matplotlib:master Jul 15, 2018
@jklymak
Copy link
Member

jklymak commented Jul 15, 2018

Thanks @joelostblom this was great...

lumberbot-app bot pushed a commit that referenced this pull request Jul 15, 2018
@joelostblom
Copy link
Contributor Author

Thanks for merging!

tacaswell added a commit that referenced this pull request Jul 15, 2018
…658-on-v2.2.2-doc

Backport PR #11658 on branch v2.2.2-doc
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