find and omit element from array

조회 수: 21 (최근 30일)
NA
NA 2019년 3월 14일
편집: NA 2019년 3월 14일
vv=(1:100)'
A=[3;8;21;44;60;79;99]
f_vv=find(vv==A);
vv(reshape(f_vv,length(f_vv),1))=[];
I got this error
Dimensions of arrays being concatenated are not consistent.

채택된 답변

madhan ravi
madhan ravi 2019년 3월 14일
편집: madhan ravi 2019년 3월 14일
21;44
% ^
vv(ismember(vv,A))=[]

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Creating and Concatenating Matrices에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by