I recently wanted a colormap that was distinctive. I wanted the zero values to be one color while the negative and positive values were different shades. This video shows how to do this interactively. The skills shown here work for lots of different colormap tasks.
You can follow any comments to this entry through the RSS 2.0 feed.
You can skip to the end and leave a comment. Pinging is currently not allowed.
1 CommentsOldest to Newest
My pedestrian solution takes just a few lines of code. I use the signed most negative and most positive values from the data and sum them. Then I use both the numerical result and its sign to assign the limits automatically. This should anchor the white of the colorbar to zero.
This is a demonstrative pseudocode:
D = maxpos+maxneg
if D >0 % abs (maxpos) > abs (maxneg)
In your case maxpos=8 and maxneg=-6