summaryrefslogtreecommitdiff
path: root/numpy/doc/basics.py
diff options
context:
space:
mode:
authorCharles Harris <charlesr.harris@gmail.com>2008-10-21 20:13:17 +0000
committerCharles Harris <charlesr.harris@gmail.com>2008-10-21 20:13:17 +0000
commit78733509e3a1f61c454fb23bae857e6a56a225de (patch)
tree7ef20e6f39d75bcae270227a32a7a211aac5b9b8 /numpy/doc/basics.py
parent8d08b753f79d798525d59ef5ccd4ea17b0f337df (diff)
downloadnumpy-78733509e3a1f61c454fb23bae857e6a56a225de.tar.gz
Change way maximum and minimum deal with nans.
Add ufuncs fmax and fmin. In the following, a complex number is considered a nan if the real or imaginary part is nan. This means that there are many different complex numbers that are nans and this effects the nan values returned by the maximum, minimum, fmax, and fmin ufuncs. The maximum and minimum ufuncs are the same as before unless nans are involved. In the case of nans, if both values being compared are nans, then the first is returned, otherwise the nan value is returned. This has the effect of propagating nans. The fmax and fmin ufuncs return the same values as maximum and minimum if neither value being compared is nan. In the case of nans, if both values being compared are nans, then the first is returned, otherwise the non-nan value is returned. This has the effect that nans are ignored unless both values are nan.
Diffstat (limited to 'numpy/doc/basics.py')
0 files changed, 0 insertions, 0 deletions