eq
Element-wise equality test (function form of ==).
Syntax
Section titled “Syntax”C = eq(A, B)Description
Section titled “Description”Returns a logical array where each element is true if A(i) == B(i). NaN values are unequal to themselves.
Example
Section titled “Example”eq([1 2 3], [1 0 3]) % [1 0 1]See also
Section titled “See also”ne— Element-wise inequality test (function form of~=).isequal— Test whether two or more inputs are equal in shape and value.equalwithequalnans— Element-wise equality with NaN treated as equal to NaN.