Charles R Harris wrote: > > I'm also wondering about the sign ufunc. It should probably return nan > for nans, but -1,0,1 are the current values. We also need to decide > which end of the sorted values the nans should go to. I'm a bit > partial to the beginning but the end would be fine with me, it might > even be a bit more natural as searchsorted would find the beginning of > the nans by default.
Note that in both suggest approaches, sort with NaN would raise an error. We could then provide a nansort, which ignore the NaN, and deal with your case; would it be hard to have an option for the beginning vs the end, or would that be difficult ? cheers, David _______________________________________________ Numpy-discussion mailing list Numpy-discussion@scipy.org http://projects.scipy.org/mailman/listinfo/numpy-discussion