Filter löschen
Filter löschen

Linear Scale on Logarithmic Colorbar

87 Ansichten (letzte 30 Tage)
Douglas Anderson
Douglas Anderson am 21 Nov. 2022
Beantwortet: Douglas Anderson am 22 Nov. 2022
Hello!
I am using a logarithmic colorbar over a limited range of values. The colorbar shows the log values, just the exponents. Is there a way to show the actual linear values on the colorbar?
Here's a dummy example.
Linear Log
Would like the numbers on the log scale instead of the exponent values.
Thanks!
Doug Anderson

Akzeptierte Antwort

Douglas Anderson
Douglas Anderson am 22 Nov. 2022
OK, I figured this out. For this case:
colormap;
set(gca,'colorscale','log');
cbar = colorbar;
cbar.Ticks = [0.125,0.25,0.5,1,1.5,2];
Doug Anderson

Weitere Antworten (0)

Kategorien

Mehr zu Colormaps finden Sie in Help Center und File Exchange

Produkte


Version

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by