How to compare two table?

31 views (last 30 days)
fyza affandi
fyza affandi on 27 Nov 2018
Answered: Peter Perkins on 27 Nov 2018
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)

Accepted Answer

madhan ravi
madhan ravi on 27 Nov 2018
Edited: madhan ravi on 27 Nov 2018

More Answers (1)

Peter Perkins
Peter Perkins on 27 Nov 2018
See the documentation for ismember. You want 'rows'.

Categories

Find more on Tables in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!