필터 지우기
필터 지우기

Removing 1 column of ydata

조회 수: 1 (최근 30일)
Benjamin
Benjamin 2012년 6월 5일
Hi there, I was wondering if there was a way to delete a single column of ydata in a plot without having to do it manually each time?
Thanks, Ben

채택된 답변

Walter Roberson
Walter Roberson 2012년 6월 5일
... Just don't plot it?
not_col = 7; %for example
yt = ydata;
yt(:,not_col) = [];
plot(yt)
or
not_col = 7; %for example
plot( ydata(:, setdiff(1:size(ydata,2), not_col) ))
  댓글 수: 1
Benjamin
Benjamin 2012년 6월 6일
Thanks so much Walter, still trying to learn MatLab and this did the trick perfectly.

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

추가 답변 (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