필터 지우기
필터 지우기

Plotting with different colors

조회 수: 1 (최근 30일)
Aftab Ahmed Khan
Aftab Ahmed Khan 2014년 10월 10일
댓글: Aftab Ahmed Khan 2014년 10월 10일
Hi everyone, i want to plot these graphs wtih different colors as at the moment all of them are black. This plot command is inside the loop, each time it plots one curve on the figure window. So i want each time it plots the graph with different color. Thank you so much.
plot(ITstore,bptime,'-k','LineWidth',2);

채택된 답변

Image Analyst
Image Analyst 2014년 10월 10일
  댓글 수: 1
Aftab Ahmed Khan
Aftab Ahmed Khan 2014년 10월 10일
Hi, this thread solved it for me. thank you.

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

추가 답변 (1개)

Azzi Abdelmalek
Azzi Abdelmalek 2014년 10월 10일
Don't specify the color k
plot(ITstore,bptime,'-','LineWidth',2)
  댓글 수: 2
Aftab Ahmed Khan
Aftab Ahmed Khan 2014년 10월 10일
Hi, if i don't specify the color, then i am getting all of them in blue color. as shown below
Azzi Abdelmalek
Azzi Abdelmalek 2014년 10월 10일
Look at this example
x=linspace(0,10,100);
y=[sin(x)' cos(x)']
plot(x,y,'-')

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

카테고리

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