필터 지우기
필터 지우기

Why is my plot missing lines?

조회 수: 7 (최근 30일)
lil brain
lil brain 2022년 3월 2일
댓글: lil brain 2022년 3월 2일
Hi,
I have a matrix called comparisontable_abs and when I plot it using the plot() function, I get a plot which looks right but is missing two lines. Since the matrix comparisontable_abs contains 9 rows I expect there to be 9 lines but the plot only shows 6. Why is that?
Thanks!
My code:
plot(comparisontable_abs);
xlabel('Participants')
ylabel('Hurst exponent')
legend('head - balls glitch', 'left hand - balls glitch', 'right hand - balls glitch',...
'head - baskets glitch', 'right hand - baskets glitch', 'left hand - baskets glitch',...
'head - non-glitch', 'right hand - non-glitch', 'left hand - non-glitch')
grid on
title ('[HIGH] Difference in Hurst (distances) between ball, basket and no glitch')
newcolors = {'red','red','red','yellow','yellow','yellow','green','green','green'};
colororder(newcolors);

채택된 답변

Davide Masiello
Davide Masiello 2022년 3월 2일
편집: Davide Masiello 2022년 3월 2일
It actually plots 9 lines, but the 1st and 2nd are equal, and the same goes for the 4th and 5th, and 7th and 8th.
So they overlap in you plot.

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by