jiffyclub / palettable

Color palettes for Python
https://jiffyclub.github.io/palettable/
Other
768 stars 73 forks source link

feature request: add CartoColor color schemes #20

Closed andy-esch closed 7 years ago

andy-esch commented 7 years ago

They exist as a node module: https://github.com/CartoDB/cartocolor Visuals here: https://github.com/CartoDB/CartoColor/wiki/CARTOColor-Scheme-Names

I'll happily provide a PR if @jiffyclub / community agrees, just want to get an ok here :)

jiffyclub commented 7 years ago

This would be great! The cmocean module might be a good template to follow. https://github.com/jiffyclub/palettable/tree/master/palettable/cmocean

andy-esch commented 7 years ago

Great, I'll take a crack at it :)

andy-esch commented 7 years ago

It looks like the format its most similar to colorbrewer since there are diverging, sequential, and qualitative palettes, each with a specified number of colors? https://github.com/CartoDB/CartoColor/blob/master/cartocolor.js vs. https://github.com/jiffyclub/palettable/blob/master/palettable/colorbrewer/data/colorbrewer_all_schemes.json

jiffyclub commented 7 years ago

Yeah cmocean also multiple types (sequential and diverging), but its maps also have much larger sets of colors. cmocean was implemented much more recently so in that sense I'd prefer you tried to copy it's high level implementation, but it might need to be adapted in some ways to be closer to colorbrewer in terms of the supported number of colors.

andy-esch commented 7 years ago

Completed in #21 :)