
Just feed a valid colormap name and they will respectively set it up for the current figure or return the corresponding RGB values. The set_palette and get_palette commands wrap all the provided colormap packages, exposing to the user a very simple and intuitive interface. So let's start now describing the colortools! Select all available colormaps via set_palette/ get_palette RGB colorname package, to allow selecting colors by their conventional names.These are thoroughly documented in specific READMEs, to which we'll refer whenever appropriate: Ideally the user would mostly use just these, although lower level machinery is made available by means of specialized namespaces. The higher level API consists of the functions included in the colortools folder.

BONUS: the legendary cprintf, for colorful terminal output (with caveats)Ĭlone the repository somewhere in your machine.Additional interactive functionality through view_color.Build fully custom diverging colormaps through diverging_cmap.Get color by its common name via str2rgb.HEX to RGB and viceversa through hex2rgb and rgb2hex.

Preset parameters for colormap generators via preset_palette.Pick a palette as your color order via set_colororder.Select all available colormaps via set_palette/ get_palette.The codebase mainly embeds several functions and packages by these two authors, retrieved either from the file-exchange or github and then appropriately tweaked/extended, while providing some common wrappers and tools.Īll for a unified user experience. Stephen Cobeldick, refined matlab programmer and color-theory expert. Greene, one of the coauthors of the cmocean launch paper and prolific matlab-file-exchange contributor. So here we provide a fair amount of such new color functionality, building up on the firm shoulders of two giants:Ĭhad. Nowadays it's embedded again in matplotlib and available in LaTeX, in R, and Julia. Meanwhile the results of a totally crazy and marvelous at the same time 2010 color survey made by the great xkcd webcomic, have gained more and more popularity, in fact challenging the old and trusted X11 colorset. So we had Dave Green's 2011 paper introducing a new, revolutionary, colormap with the aim of representing astronomical data with monotonically increasing brightness (and so black-and-white print friendliness) then in 2015 even better advances by the SciPy team, enriching matplotib with beautiful perceptually uniform colormaps ( viridis, magma, plasma and the domain-specific ones for oceanography: cmocean).

In recent years, though, one important aspect has greatly evolved in the plotting business: color management. COLORLAB a curated collection of color-related MATLAB librariesįor a long time Matlab has excelled for its plotting features, at a point where matplotlib, arguably the most popular open-source plotting library nowadays, has started as an explicit clone of such functionality and still today keeps a strong influence.
