Identifying missing values in matrices

4 views (last 30 days)
I have two matrices. A=429x1 and B=412x1
Every number in the B matrix exists in A. However I want to find out which numbers are missing in B. Like
C=17x1

Accepted Answer

David Fletcher
David Fletcher on 6 Apr 2021
try
idx=~ismember(B,A)
C=A(idx)

More Answers (0)

Categories

Find more on Matrices and Arrays in Help Center and File Exchange

Products

Community Treasure Hunt

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

Start Hunting!