LineWidth PROPERTY "plot command error"

조회 수: 6 (최근 30일)
MASTER WHOS
MASTER WHOS 2019년 2월 14일
댓글: MASTER WHOS 2019년 2월 14일
1-What might be the problem? 2-What does linewidth property mean? 3-What to do?
[I am using matlab R2016b]
When I want to plot line with color and certain width, I recceive an error:
THE COMMAND
plot(SNR_db,Pd_NSP_cat_mean(:,2),'b','LineWidth',2.5)
THE ERROR:
Error using plot
There is no LineWidth property on the Line class.
Error in PROJECTION_BASED_SHARING (line 76)
plot(SNR_db ,Pd_NSP_cat_mean(:,1),'g','LineWidth ',2.5)

채택된 답변

Geoff Hayes
Geoff Hayes 2019년 2월 14일
Look closely at your line of code
plot(SNR_db ,Pd_NSP_cat_mean(:,1),'g','LineWidth ',2.5)
There is an extra space after LineWidth. Try removing the space and try again like with
plot(SNR_db ,Pd_NSP_cat_mean(:,1),'g','LineWidth',2.5)
(the above seemed to fix it for me).
  댓글 수: 1
MASTER WHOS
MASTER WHOS 2019년 2월 14일
THANK YOU VERY MUCH IT WORKED :)

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Annotations에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by