NumPy · Function
np.setdiff1d
np.setdiff1d returns the unique values in one array that are missing from another. By default, it returns the result in sorted order.
Last updated
Syntax
numpy.setdiff1d(ar1, ar2, assume_unique=False)In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.
SubscribeRelated
numpy.ma.setdiff1dnumpy.intersect1dnumpy.union1d