File Exchange

image thumbnail

crameri perceptually uniform scientific colormaps

version 1.05 (862 KB) by Chad Greene
Perceptually uniform scientific colormaps from Fabio Crameri.


Updated 28 Sep 2018

View License

When color is a numerical axis, it should not be distorted.

This function is similar to the cmocean (Thyng et al., 2016) function also found on File Exchange, but this one's for Fabio Crameri's colormaps (Crameri 2018a,b).

Crameri, F. (2018). Scientific colour-maps. Zenodo.

Crameri, F. (2018), Geodynamic diagnostics, scientific visualisation and StagLab 3.0, Geosci. Model Dev., 11, 2541-2562, doi:10.5194/gmd-11-2541-2018 .

Thyng, K. M., Greene, C. A., Hetland, R. D., Zimmerle, H. M., & DiMarco, S. F. (2016). True colors of oceanography: Guidelines for effective and accurate colormap selection. Oceanography, 29(3), 9-13.

Cite As

Chad Greene (2020). crameri perceptually uniform scientific colormaps (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (7)

Matti Kummu

E. Cheynet

Chad Greene

@Stephen, you are quite thorough! Thanks, I've edited the input checking as you suggested.

A tidy function and a useful addition to FEX. Well documented, as all of Chad Greene's FEX submissions are. Thank you Chad!

I note that the code used to check for the '-' character is not limited to one at the beginning of the string, so 'Col-orName', or 'ColorN-ame', or even 'C-o-l-o-r-N-a-m-e' would also pass. Is this intentional? STRNCMP would give the documented behavior.

Fabio C



Previously forgot to include turku. All of them should be in there now.


Added oslo colormap (previously forgot to include it in the .mat file).


Changed screenshot.


Updated screenshot and edited input checking (regexp replaced with strncmp, as suggested by Stephen Cobeldick).


Published as a .zip because the .mltbx upload failed.

MATLAB Release Compatibility
Created with R2017b
Compatible with any release
Platform Compatibility
Windows macOS Linux

Inspired by: cmocean perceptually-uniform colormaps