[Numpy-discussion] Sign of NaN

Freddy Rietdijk freddyrietdijk at fridh.nl
Tue Sep 29 11:17:58 EDT 2015


I wouldn't know of any valid output when applying the sign function to NaN.
Therefore, I think it is correct to return a ValueError. Furthermore, I
would prefer such an error over just returning NaN since it helps you
locating where NaN is generated.

On Tue, Sep 29, 2015 at 5:13 PM, Charles R Harris <charlesr.harris at gmail.com
> wrote:

> Hi All,
>
> Due to a recent commit, Numpy master now raises an error when applying the
> sign function to an object array containing NaN. Other options may be
> preferable, returning NaN for instance, so I would like to open the topic
> for discussion on the list.
>
> Thoughts?
>
> Chuck
>
> _______________________________________________
> NumPy-Discussion mailing list
> NumPy-Discussion at scipy.org
> https://mail.scipy.org/mailman/listinfo/numpy-discussion
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20150929/0680eeb4/attachment.html>


More information about the NumPy-Discussion mailing list