Say I have a numpy array of strings:
arr = np.array(['cat', 'dog', 'bird', 'swiss army knife'])
and I want to remove the string 'swiss army knife'.
What is the best way to do this?
It seems like something that should be very straight forward, but yet I haven't found a solution that doesn't involve sorting and/or finding the index of the element and use that to slice the selection of the array that's needed.
np.delete
doesn't seem to work for strings.