O'Reilly logo

Matplotlib 2.x By Example by Aldrin Yim, Claire Chung, Allen Yu

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Aesthetic and readability considerations

For good readability, we recommend ample color contrast between background and foreground colors. It is also wise to keep enough contrast between data series for easy recognition. For foreground colors, we generally do not need to set the alpha value to add transparency. When in doubt, you may use or refer to the default color cycle.

For black-and-white printing, it is recommended to combine grayscale colors with different line styles or fill patterns to distinguish between data series. Using grayscale colors has the advantage of ensuring different colors on the resultant printing, since it is possible for two colors, say red and blue, to have very similar hues and appear the same when converted to ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required