Info
이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.
Removing rows in a vector
조회 수: 1 (최근 30일)
이전 댓글 표시
So far this is my code and it correctly identifies the rows of the cells that needs to be removed: However the second line does not work, can anyone help me make it work?
if true
failed= find ((JT_S_TN(:,2)==5) | (JT_S_TN(:,2)==0));
% Finds the rows which was a faulty jump trial
corrected = removeTerms(JT_S_TN,'ind',failed); % Copies jumptypes into a new array, without the removed rows end
댓글 수: 0
답변 (1개)
dpb
2014년 5월 18일
Tutorial info -- Do NOT put blank lines in code; as you see it reverts to word wrap instead of code formatting. As previously noted, to enter code, put two blanks in front of the first line in the new paragraph.
That aside, what is removeTerms?; I don't recognize it as basic Matlab function.
If JT_S_TN is your data array, simply write
correct=JT_S_TN(~failed,:); % extract those not failed
이 질문은 마감되었습니다.
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!