[Numpy-discussion] What should be the result in some statistics corner cases?
ralf.gommers at gmail.com
Tue Jul 16 01:36:51 EDT 2013
On Tue, Jul 16, 2013 at 3:50 AM, Charles R Harris <charlesr.harris at gmail.com
> On Mon, Jul 15, 2013 at 6:58 PM, Benjamin Root <ben.root at ou.edu> wrote:
>> To add a bit of context to the question of nansum on empty results, we
>> currently differ from MATLAB and R in this respect, they return zero no
>> matter what. Personally, I think it should return zero, but our current
>> behavior of returning nans has existed for a long time.
>> Personally, I think we need a deprecation warning and possibly wait to
>> change this until 2.0, with plenty of warning that this will change.
> Waiting for the mythical 2.0 probably won't work ;) We also need to give
> folks a way to adjust ahead of time. I think the easiest way to do that is
> with an extra keyword, say nanok, with True as the starting default, then
> later we can make False the default.
No special keywords to work around behavior change please, it doesn't work
well and you end up with a keyword you don't really want.
Why not just give a FutureWarning in 1.8 and change to returning zero in
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the NumPy-Discussion