Effacer les filtres
Effacer les filtres

how to set colorbar not showing values

2 vues (au cours des 30 derniers jours)
nirit
nirit le 18 Oct 2016
I have grayscale image with values 0, 11-max(image). I want to show 0 as black , and 11-max(image) as different type of red.
my questions are:
1.how to change the colorbar accordingly? I dont mind showing 0-11 as black, but it will be best if the values 1-10 will not shown at all at the colorbar. or , in other words, can I show at the colorbar only the values :0,11-end?
2. how to make the quantization of the red seem good? (so that the human eye could make the different between the shades )
please help?
thank you.

Réponses (1)

Walter Roberson
Walter Roberson le 18 Oct 2016
You cannot use colorbar and have a range omitted. You could create your own colorbar replacement.
For the quantization you probably cannot do better than linspace() of the red values between some minimum and maximum in the 0 to 1 range,with number of steps equal to the greatest max value minus 9

Catégories

En savoir plus sur Blue dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by