How can I change the size of a custom colormap that I have generated in MATLAB?
Show older comments
I have a custom colormap "mycmap" which can represent 64 colors. This colormap, stored in "mycolor.mat", is a 64x3 matrix specifying the RGB values for the colors. I would like to interpolate these color values and get a larger or smaller number of colors spanning the same range of colors.
The operation would be similar to how the COLORMAP function works when given an argument specifying a certain number of colors derived from one of the built-in colormaps such as "jet", "copper", or "hsv", e.g.:
cmap = colormap(jet(99));
returns a 99-by-3 version of the "jet" colormap.
Accepted Answer
More Answers (0)
Categories
Find more on Blue in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!