|
38 | 38 |
|
39 | 39 | # Flat list used by param.Selector for validation. |
40 | 40 | CURATED_COLORMAPS: list[str] = [ |
41 | | - # Sequential — single-hue / perceptually uniform |
42 | | - "viridis", |
43 | | - "plasma", |
44 | | - "inferno", |
45 | | - "magma", |
46 | | - "Blues", |
47 | | - "YlOrRd", |
48 | | - "turbo", |
49 | | - "rainbow", |
| 41 | + # Sequential — perceptually uniform, colorblind-safe (recommended) |
| 42 | + "viridis", # perceptually uniform; safe for all dichromacy types |
| 43 | + "plasma", # warm alternative; high discrimination |
| 44 | + "cividis", # optimized specifically for deuteranopia (Nuñez et al. 2018) |
| 45 | + "inferno", # high contrast on dark backgrounds |
| 46 | + "magma", # high contrast on dark backgrounds |
| 47 | + # Sequential — domain-intuitive |
| 48 | + "cet_fire", # black→blue→orange→white; dark=fresh, bright=saline (EC) |
| 49 | + "cet_CET_L2", # blue→green→yellow; strong water-level intuition |
| 50 | + "Blues", # water-blue association; not perceptually uniform |
| 51 | + "YlOrRd", # warm; intuitive for heat / conductivity |
| 52 | + # Sequential — high-contrast (not colorblind-safe) |
| 53 | + "turbo", # good contrast; not perceptually uniform; not colorblind-safe |
50 | 54 | # Diverging — two-hue, centred on a neutral midpoint |
51 | | - "coolwarm", |
52 | | - "RdBu_r", |
53 | | - "RdYlBu_r", |
54 | | - "PiYG", |
55 | | - "bwr", |
56 | | - "seismic", |
| 55 | + "coolwarm", # best general-purpose diverging; perceptually symmetric |
| 56 | + "RdBu_r", # blue=negative/upstream, red=positive/downstream convention |
| 57 | + "RdYlBu_r", # yellow midpoint aids near-zero discrimination |
| 58 | + "cet_CET_D9", # blue→yellow→red; colorblind-accessible diverging |
| 59 | + "PiYG", # pink/green; useful for anomaly-style differences |
57 | 60 | ] |
58 | 61 |
|
59 | 62 | # Flat list for pn.widgets.Select that includes a visual separator. |
60 | 63 | # The separator string is not a valid colormap — callbacks guard against it. |
61 | 64 | _COLORMAP_SEPARATOR = "── Diverging ──" |
62 | 65 | CURATED_COLORMAPS_WITH_SEP: list = [ |
63 | | - "viridis", "plasma", "inferno", "magma", "Blues", "YlOrRd", "turbo", "rainbow", |
| 66 | + "viridis", "plasma", "cividis", "inferno", "magma", |
| 67 | + "cet_fire", "cet_CET_L2", "Blues", "YlOrRd", "turbo", |
64 | 68 | _COLORMAP_SEPARATOR, |
65 | | - "coolwarm", "RdBu_r", "RdYlBu_r", "PiYG", "bwr", "seismic", |
| 69 | + "coolwarm", "RdBu_r", "RdYlBu_r", "cet_CET_D9", "PiYG", |
66 | 70 | ] |
67 | 71 |
|
68 | 72 | # --------------------------------------------------------------------------- |
|
0 commit comments