This is an embarrassingly simple function to augment the currently available MATLAB colormaps. It works as a seamless replacement for the current maps like jet and hsv. So to use it you just call colormap(othercolor('colorname')). The function handles interpolating to any number of points (othercolor('colorname',numpoints)) and uses the current axis as the reference if numpoints is not specified.
The available maps are stored in the file colorData.mat and you can easily add your own maps. To get a list of available names just call othercolor() without any arguments.
The 400+ colormaps are from 3 sources:
Mathematica (indexed, physical, gradient, and named)
Some of these maps are better suited for sets of bar or line plots (particularly the qualitative sets). In those cases the last number in the name is the number of indexed colors, so it would probably be fitting to set M to that number to avoid interpolation. Example:
>> colorscheme = othercolor('Set16',6);
* I'm looking for ideas on how to best organize these maps now that there are 400+ of them. If you have suggestions please leave them in the comments or send me an email.
Joshua Atkins (2021). othercolor (https://www.mathworks.com/matlabcentral/fileexchange/30564-othercolor), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Platform CompatibilityWindows macOS Linux
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!