Moving the position of the colorbar label
21 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Wissem-Eddine KHATLA
le 31 Mar 2024
Commenté : Wissem-Eddine KHATLA
le 1 Avr 2024
Hello everyone,
Is there a way to move the position of the decimal power in the colorbar axis shown in the figure attached to this post ? More specifically, I want to move
a little bit on the left.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1656131/image.png)
Thank you in advance for your help,
Sincerely.
0 commentaires
Réponse acceptée
the cyclist
le 1 Avr 2024
Modifié(e) : the cyclist
le 1 Avr 2024
figure
surf(1e7*peaks)
c = colorbar;
drawnow()
c.Ruler.SecondaryLabel.Units = 'normalized';
c.Ruler.SecondaryLabel.Position = [1 0.9];
I tried to run this code here, but got an error message. (According to this question, it seems there is a problem running code at Answers at the moment.) It runs on my local machine, though. In this case, I moved the label down from the default position. Adjust as you see fit.
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Orange 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!