Filter löschen
Filter löschen

How to change color bar for images function?

17 Ansichten (letzte 30 Tage)
NeoBeaver
NeoBeaver am 19 Aug. 2016
Kommentiert: NeoBeaver am 20 Aug. 2016
Dear all:
Any one could help me with this problem:
I used the following piece of code to generate a heat map for a matrix:
clf
imagesc(full_B);
colorbar;
The color bar default look like this:
I am thinking about changing the color bar into something like rainbow.
How should I be doing it?
Thanks! Ruming

Akzeptierte Antwort

Image Analyst
Image Analyst am 19 Aug. 2016
Try this
imagesc(full_B);
colorbar;
colormap(jet(256));
or even better:
imshow(full_B, []);
colorbar;
colormap(jet(256));

Weitere Antworten (0)

Kategorien

Mehr zu Orange finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by