Effacer les filtres
Effacer les filtres

How to change color of x and y axis by red and blue

23 vues (au cours des 30 derniers jours)
Atom
Atom le 7 Mai 2013
I want to change the color of each axis by red & blue?
x=0:.1:1
axis([0 1 0 1]);
y=x.*(1-x);
plot(x,y,'g');
hold on
line([0 0], [0 1]);
hold on
line([0 1], [0 0]);

Réponse acceptée

Azzi Abdelmalek
Azzi Abdelmalek le 7 Mai 2013
set(gca,'xcolor','r','ycolor','b')

Plus de réponses (0)

Community Treasure Hunt

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

Start Hunting!

Translated by