[Numpy-discussion] Behavior of nan{max, min} and nanarg{max, min} for all-nan slices.

Benjamin Root ben.root at ou.edu
Wed Oct 2 15:04:56 EDT 2013

On Wed, Oct 2, 2013 at 2:05 PM, Stéfan van der Walt <stefan at sun.ac.za>wrote:

> On 2 Oct 2013 19:14, "Benjamin Root" <ben.root at ou.edu> wrote:
> >
> > And it is logically consistent, I think.  a[nanargmax(a)] == nanmax(a)
> (ignoring the silly detail that you can't do an equality on nans).
> Why do you call this a silly detail? It seems to me a fundamental flaw to
> this approach.
> Just saying that it conceptually makes sense, even if the exact code I
used wouldn't be perfectly correct. Because these are NaN functions, it
means that the users are already aware of the need to handle nans
appropriately. Just because you can't actually do equality between two NaNs
in the same way as one can do with numbers does not invalidate the concept.

Ben Root
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20131002/c0f7cd3c/attachment.html>

More information about the NumPy-Discussion mailing list