Improve everyday.

Beautiful color lists

|

Create easily a list of distinct colors (for plotting or visualisation), using matplotlib.pyplot colormaps

Get the color list (RGB)

To get a list of colors, go chose the colormap you want here. Multiple shading offs are provided, as well as discrete colormaps (qualitative section).

beautiful_colormaps

You can then create n different colors by passing a list of n float uniformly spaced between 0 and 1.

Example

Here, get the 8 colors from Dark2 colormap :

import matplotlib.pyplot as plt
COLORS = plt.cm.Dark2(np.linspace(0, 1, 8))

Comments