Colormap

Colormaps are useful in showing gradient. The yellow to blue "viridis" colormap is now the default one in Matplotlib 2.0. This perceptually uniform colormap better represents the transition of numerical values visually than the classic “jet” scheme. This is a comparison between two colormaps:

Besides defaulting to a perceptually continuous colormap, qualitative colormaps are now available for grouping values into categories:

Get Matplotlib 2.x By Example now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.