[Numpy-discussion] u in [u+1]
Neal Becker
ndbecker2 at gmail.com
Fri Feb 5 06:47:06 EST 2010
I'm having some trouble here. I have a list of numpy arrays. I want to
know if an array 'u' is in the list.
As an example,
u = np.arange(10)
: u not in [u+1]
---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
/home/nbecker/raysat/test/<ipython console> in <module>()
ValueError: The truth value of an array with more than one element is
ambiguous. Use a.any() or a.all()
What would be the way to do this?
More information about the NumPy-Discussion
mailing list