a= [ 1 0 0 ; 0 0 0; 1 0 0]
new=[0 0 1] % the row to be replace
a(2,:)=new % replace row 2 in a with new
How can I compare the new table and original table to get the number of row and column of added 1 (in the new table)

추가 답변 (1개)

Peter Perkins
Peter Perkins 2018년 11월 27일

1 개 추천

See the documentation for ismember. You want 'rows'.

카테고리

도움말 센터File Exchange에서 Numeric Types에 대해 자세히 알아보기

질문:

2018년 11월 27일

답변:

2018년 11월 27일

Community Treasure Hunt

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

Start Hunting!

Translated by