Change a specific color(assigned to a value) con a colorbar?
12 views (last 30 days)
Show older comments
Hi, I have a colorbar that assigns the color blue to the value 0. I'd like to specifically assign the color 'white' to the value 0. How can this be done? Thank you!
0 Comments
Accepted Answer
Walter Roberson
on 2 Apr 2012
cmap = colormap; %current map
cmap(1,:) = [1 1 1]; %make first color white
colormap(cmap); %put it into effect
More Answers (0)
See Also
Categories
Find more on White in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!