The docs for numpy.sign at http://docs.scipy.org/doc/numpy/reference/generated/numpy.sign.html do not indicate how complex numbers are handled. Currently, np.sign appears to return the sign of the real part as a complex value. Was this an explicit choice? Was x/abs(x) considered (for non-zero elements)? Thanks, Alan Isaac
On Fri, Jul 12, 2013 at 12:53 PM, Alan G Isaac <alan.isaac@gmail.com> wrote:
The docs for numpy.sign at http://docs.scipy.org/doc/numpy/reference/generated/numpy.sign.html do not indicate how complex numbers are handled. Currently, np.sign appears to return the sign of the real part as a complex value. Was this an explicit choice? Was x/abs(x) considered (for non-zero elements)?
ISTR some discussion of that. Personally, I like the x/abs(x) idea. Chuck
participants (2)
-
Alan G Isaac -
Charles R Harris