Should we override the matplotlib color shorthands?
See original GitHub issueMatplotlib lets you specify colors like "b"
for blue, "r"
for red, etc. which is nice. But, those colors are mapped to the corners of RGB space, which, bleh.
This is additionally problematic as some functions (like plt.scatter
) hardcode these values as default.
It occurs to me that seaborn could override this by messing with the values in the mpl.colors.ColorConverter.colors
dictionary. But that might be too much manipulation?
Opening this issue for discussion.
Issue Analytics
- State:
- Created 9 years ago
- Comments:27 (19 by maintainers)
Top Results From Across the Web
matplotlib.pyplot.plot — Matplotlib 2.1.2 documentation
Line styles and colors are combined in a single format string, as in 'bo' for blue circles. The kwargs can be used to...
Read more >Increment matplotlib color cycle - python - Stack Overflow
There must be a shorthand way to instruct the second plot to increment the color cycle rather than explicitly giving the color. It...
Read more >How To Change Line Color In Matplotlib - YouTube
This video talks about the various ways to set line color in Matplotlib.Blog: http://www.shwetalodha.in/Medium: ...
Read more >Chapter 4. Visualization with Matplotlib - O'Reilly
Just as we use the np shorthand for NumPy and the pd shorthand for Pandas, we will use some standard shorthands for Matplotlib...
Read more >Line plot styles in Matplotlib - GeeksforGeeks
The following line styles are available in Matplotlib: ... Color code abbreviations that can be used along with the line styles: ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
For what it’s worth, I think this would be fine (and appreciated). Users who are concerned preserving the exact original styling of their matplotlib figures won’t be using
import seaborn
anyways.Thanks, I see the fix in 0.5.1, sorry to muddle the current thread.