matplotlib / cmocean

Colormap setup for standardizing commonly-plotting oceanographic variables.
MIT License
230 stars 52 forks source link

Phase, but with grey #108

Open spinicist opened 6 months ago

spinicist commented 6 months ago

Hello,

Apologies, this is more of a discussion than an issue but I didn't know where else to ask.

tl;dr: Would it be meaningful to create a version of the phase colormap that goes through the appropriate grey at the center of the scale?

Rationale: I work a lot with complex valued data. I find it useful to plot this using the phase colormap or similar to represent the phase, and then scale the intensity/luminance by the magnitude of my data. However, my field is used to looking at greyscale magnitude images only. Hence I've long wondered if the two couldn't be combined, whereby positive real values would still use greyscale, and then any data that has non-zero phase would have the hue shifted. As the phase colormap has a flat lightness value, couldn't the central blue-ish color be swapped out for grey? I suspect I'm forgetting some color theory as to why this is a bad idea. Thanks for any insights anyone can provide.

spinicist commented 6 months ago

PS - Is the actual lightness value of the phase map documented somewhere?