This function creates a new set of invisible axes matching the size and extents of the current axes. This allows additional colormaps to be used in such a way that they are perceived as multiple colormaps in the same axes.
Chad Greene (2021). newcolorbar: multiple colormaps in the same axes (https://www.mathworks.com/matlabcentral/fileexchange/52505-newcolorbar-multiple-colormaps-in-the-same-axes), MATLAB Central File Exchange. Retrieved .
Inspired by: freezeColors / unfreezeColors, COLORMAP and COLORBAR utilities (Jul 2014), Multiple Colormaps, ColorBrewer: Attractive and Distinctive Colormaps
Inspired: cbarrow: pointy ends for colorbars
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Create scripts with code, output, and formatted text in a single executable document.
Ah no 2014b is enough. Still, does not work for map axes...
Error using gcm (line 25)
Not a map axes.
Error in nextmap (line 24)
gcm; % Will error if gca is not a valid map axes
Error in pcolorm (line 46)
nextmap;
Does it only work in a Matlab R2015a and higher?
It does not work for map axis...