How to change axis color in matlab?

2 vues (au cours des 30 derniers jours)
Demeter Andreea
Demeter Andreea le 14 Août 2019
Commenté : dpb le 14 Août 2019
Hello again!
Can someone help me with a problem please? How to change axis color in matlab for this code:
Im = imread('4.png');
AxesH = axes('units','pixels','position', [320, 80, 290, 330], 'Visible', 'off');
image(Im, 'Parent', AxesH);
  2 commentaires
Demeter Andreea
Demeter Andreea le 14 Août 2019
I already got the answer, thanks anyway guys :*
Put this after the code:
ax = gca;
ax.XColor = 'r'; % Red
ax.YColor = 'b'; % Blue
dpb
dpb le 14 Août 2019
For future reference, there's a link to axes properties in the documentation for Axes that will let you find all exposed properties.
Or, if you just type ax. at the command line, the auto-complete box will pop up and give you a list of properties from which to choose...

Connectez-vous pour commenter.

Réponses (0)

Community Treasure Hunt

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

Start Hunting!

Translated by