How to change the color of plotting lines
858 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Hi,
I have multiple lines to plot but by defualt they are different color, how to change the color to uniform color?
I tried to do this but failed (see below)
![QQ截图20190618140313.png](https://www.mathworks.com/matlabcentral/answers/uploaded_files/225273/image.png)
![QQ截图20190618140358.png](https://www.mathworks.com/matlabcentral/answers/uploaded_files/225274/image.png)
0 Kommentare
Akzeptierte Antwort
Adam Danz
am 18 Jun. 2019
The line of code that apparently does the plotting is cut off in your image.
Either specify the color during plotting
plot(x,y,'color', 'b');
or set the color later using the output handles
h = plot(x,y);
set(h, 'Color', 'b')
2 Kommentare
Siehe auch
Kategorien
Mehr zu 2-D and 3-D Plots finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!