proplot icon indicating copy to clipboard operation
proplot copied to clipboard

add more color blind-friendly default color cycle

Open syrte opened this issue 1 year ago • 0 comments

We may consider adding some more colorblind-friendly color schemes. See some discussion at https://github.com/matplotlib/matplotlib/issues/9460 I just take some notes here for future reference.

Several options

  • Okabe & Ito's palette, adopted by Wong https://www.nature.com/articles/nmeth.1618 Recommended by Wilke Fundamentals of Data Visualization, also probably used in Hastie+ The Elements of Statistical Learning.
# Okabe and Ito color palette
colors = ['#E69F00', '#56B4E9', '#009E73', '#F0E442', '#0072B2', '#D55E00', '#CC79A7']
# Matthew A. Petroff, arxiv:2107.02270
# 6 colors
colors = ["#5790fc", "#f89c20", "#e42536", "#964a8b", "#9c9ca1", "#7a21dd"]

# 8 colors
colors = ["#1845fb", "#ff5e02", "#c91f16", "#c849a9", "#adad7d", "#86c8dd", "#578dff", "#656364"]

# 10 colors
colors = ["#3f90da", "#ffa90e", "#bd1f01", "#94a4a2", "#832db6", "#a96b59", "#e76300", "#b9ac70", "#717581", "#92dadd"]

Petroff's paper has not been published yet. I guess (hope) that the matplotlib community may potentially take Petroff's schemes after the acceptance of the paper.

syrte avatar May 13 '23 19:05 syrte