Colormap Catalog#
To use any colormap in the catalog, you can pass its name to the Colormap constructor:
from cmap import Colormap
cmap = Colormap("viridis")
Coming from matplotlib?
We test against all of the named colormaps in matplotlib, so any 'name' that you can use with matplotlib.colormaps['name'] can also be passed to cmap.Colormap. To convert a cmap.Colormap to a native matplotlib.colors.Colormap instance, you may call .to_mpl().
See Colormaps for how to apply it to your data, and the Colormap API docs for details.
Tip: Reversed colormaps
You can append '_r' to any of the colormap names listed below to get a reversed version of that colormap. For example, 'viridis_r'
This works with function based colormaps as well:
All colormaps#
Filter by name, source, or lightness profile below, or compare colormaps side by side.
No colormaps match these filters.