You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
allow the palette to be an argument so users can choose a custom palette.
Reducing the duplication should be straight forward. Allowing arbitrary palettes might be more difficult. Does the current code assume palettes of a certain length?
The text was updated successfully, but these errors were encountered:
Does the current code assume palettes of a certain length?
Yes. I think I could make the custom palette work and apply proper normalization. If we set a default with the current palette, then that would fix the duplication problem too (of course this logic would need to be moved from static, to grabbing the palette somewhere from the generated HTML).
Ideally, we could accept any matplotlib colormap (https://matplotlib.org/users/colormaps.html). There are a few coloring issues I'd like to take care of in the next month, I'll try to sink my teeth into them when I get a chance
custom color palettes
With a discrete coloring_function, we shouldn't average the value to choose the color, instead take the majority
Toggle between multiple coloring_functions so we can easily compare.
Currently, the color palette is hardcoded in visuals.py:
https://github.com/MLWave/kepler-mapper/blob/0dfa7f736bd4218e8996888785b9d2adc63d5344/kmapper/visuals.py#L8-L15
and again in kmapper.js
https://github.com/MLWave/kepler-mapper/blob/0dfa7f736bd4218e8996888785b9d2adc63d5344/kmapper/static/kmapper.js#L25-L32
I'd like to see this
Reducing the duplication should be straight forward. Allowing arbitrary palettes might be more difficult. Does the current code assume palettes of a certain length?
The text was updated successfully, but these errors were encountered: