Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request: (diverging) bipolar colormaps #60

Open
briochemc opened this issue Mar 10, 2021 · 3 comments
Open

Request: (diverging) bipolar colormaps #60

briochemc opened this issue Mar 10, 2021 · 3 comments

Comments

@briochemc
Copy link

Request: (diverging) bipolar colormaps

I'd like to suggest the addition of diverging bipolar colormaps, such as those mentioned in matplotlib/matplotlib#6033 that ended up being encoded in https://github.com/endolith/bipolar-colormap I think, for example. What do you think?

Copying images in the ReadMe of https://github.com/endolith/bipolar-colormap for issue reader's convenience below. 😄

Subrequest

I'd like to also suggest some more freedom on these, in particular remove the part which swaps colors depending on the neutral (central) color, so that one could make a cyan-darkblue-white-darkred-yellow colormap for example. FWIW, the swapping comes from the MATLAB bipolar colormap, on which https://github.com/endolith/bipolar-colormap is built, AFAICT. And from the MATLAB function's docs:

% The colormap goes from cyan-blue-neutral-red-yellow if neutral is < 0.5
% (the default) and from blue-cyan-neutral-yellow-red if neutral > 0.5.

Workaround?

Alternatively, maybe this is better achieved by hand using, e.g., ColorSchemeTools, but I'm sure by doing this I'm not including all the nice details and thinking that went into https://github.com/endolith/bipolar-colormap to make his colormaps, so maybe someone has some better ideas?

Some examples I tried with ColorSchemeTools.jl 😃:

Screen Shot 2021-03-10 at 11 28 41 am

@rafaqz
Copy link
Collaborator

rafaqz commented Mar 10, 2021

Looks good to me!

@cormullion
Copy link
Member

It's easy to add the hotcold schemes as is, if we can get the list of RGB values. But if you want to have modified versions, perhaps you could be the one to specify the data points? Upload them somewhere then they're easily added to the collection.

The addition of Bezier interpolation to ColorSchemeTools is awaiting contributions... 😂

@stevengj
Copy link

From the readme of bipolor-colormap:

This is not a modern well-designed colormap; it's not perceptually uniform, does not have uniform lightness steps, and the endpoints are not equal lightness. But it looks nice for some purposes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants