NumPy · Function
np.intersect1d
Find the sorted, unique values shared by two arrays. You can also return the first matching index in each input.
Last updated
Syntax
numpy.intersect1d(ar1, ar2, assume_unique=False, return_indices=False)In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.
SubscribeRelated
numpy.ma.intersect1dfunctools.reduce