필터 지우기
필터 지우기

How to change the color of plotting lines

조회 수: 549 (최근 30일)
ZC Song
ZC Song 2019년 6월 18일
댓글: Adam Danz 2019년 6월 18일
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
QQ截图20190618140358.png

채택된 답변

Adam Danz
Adam Danz 2019년 6월 18일
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
ZC Song
ZC Song 2019년 6월 18일
Great it works!
Thank you very much!
Adam Danz
Adam Danz 2019년 6월 18일
Glad I could help!

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by