TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

A Better Default Colormap for Matplotlib

114 pointsby martianalmost 9 years ago

15 comments

staredalmost 9 years ago
When it comes to plot colors in matplotlib, it&#x27;s why I start with<p>import seaborn as sns<p>to get a nice plot theme, not &quot;good old 90s&quot; style. See: <a href="https:&#x2F;&#x2F;speakerdeck.com&#x2F;pmigdal&#x2F;teaching-machine-learning?slide=5" rel="nofollow">https:&#x2F;&#x2F;speakerdeck.com&#x2F;pmigdal&#x2F;teaching-machine-learning?sl...</a>
评论 #11805340 未加载
jksalmost 9 years ago
This will be the default in Matplotlib 2.0, and a beta was just tagged: <a href="http:&#x2F;&#x2F;article.gmane.org&#x2F;gmane.comp.python.matplotlib.announce&#x2F;9" rel="nofollow">http:&#x2F;&#x2F;article.gmane.org&#x2F;gmane.comp.python.matplotlib.announ...</a>
julesalmost 9 years ago
In the talk when he showed the 3 similar maps getting equal score, and then the green one getting a much higher score, that could easily be because people couldn&#x27;t decide between the 3 similar maps, to they went with the one different map. To do a proper comparison the test should be 1-1 or 3-3, not 3-1.
评论 #11806643 未加载
martianalmost 9 years ago
OP here: really worth watching the embedded video on this topic. Viridis is born out of an awesome, intense deep-dive into research on human vision and perception.
franblasalmost 9 years ago
I&#x27;m mostly using seaborn (<a href="https:&#x2F;&#x2F;web.stanford.edu&#x2F;~mwaskom&#x2F;software&#x2F;seaborn&#x2F;" rel="nofollow">https:&#x2F;&#x2F;web.stanford.edu&#x2F;~mwaskom&#x2F;software&#x2F;seaborn&#x2F;</a>) to wrap matplotlib graphs but great to see a direct alternative into the matplotlib library.
xioxoxalmost 9 years ago
If you&#x27;re interested in colour maps, cubehelix [1] is a useful scheme to make intensity maps which display well when converted to greyscale.<p>[1] <a href="https:&#x2F;&#x2F;www.mrao.cam.ac.uk&#x2F;~dag&#x2F;CUBEHELIX&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.mrao.cam.ac.uk&#x2F;~dag&#x2F;CUBEHELIX&#x2F;</a>
mbostockalmost 9 years ago
I ported these color scales to d3-scale and D3 4.0:<p><a href="https:&#x2F;&#x2F;github.com&#x2F;d3&#x2F;d3-scale&#x2F;blob&#x2F;master&#x2F;README.md#sequential-scales" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;d3&#x2F;d3-scale&#x2F;blob&#x2F;master&#x2F;README.md#sequent...</a>
yoodenvranxalmost 9 years ago
I started using viridis a few weeks ago and I love it!
Aardwolfalmost 9 years ago
Is it strange that I find the old &quot;JET&quot; the best? It uses the most hues (green, yellow, red and blue are all there), so things are the most distinguishable. The others are either only blue&#x2F;green&#x2F;yellow, or only purple&#x2F;red&#x2F;yellow.
评论 #11808654 未加载
评论 #11807668 未加载
slmouradianalmost 9 years ago
I dislike that the whole page, including the updates, do not contain any dates...
评论 #11807711 未加载
tixzdkalmost 9 years ago
Javascript version: <a href="https:&#x2F;&#x2F;github.com&#x2F;politiken-journalism&#x2F;scale-color-perceptual" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;politiken-journalism&#x2F;scale-color-perceptu...</a>
jxyalmost 9 years ago
If you use gnuplot, which I do exclusively, you may like this repository:<p><pre><code> https:&#x2F;&#x2F;github.com&#x2F;Gnuplotting&#x2F;gnuplot-palettes</code></pre>
wnkrshmalmost 9 years ago
I&#x27;m pleased. They look extremely similar to the gnuplot and gnuplot2 color maps already present in matplotlib, my favorites.
donquichottealmost 9 years ago
I also enjoy using Olga Botvinnik&#x27;s prettyplotlib: github.com&#x2F;olgabot&#x2F;prettyplotlib
Bromsklossalmost 9 years ago
That was an amusing talk. I had fun watching it.