diff options
author | David Cournapeau <cournape@gmail.com> | 2009-03-06 14:36:33 +0000 |
---|---|---|
committer | David Cournapeau <cournape@gmail.com> | 2009-03-06 14:36:33 +0000 |
commit | 9064d4b2a46fc8b725314e5fae191b8497fef5f6 (patch) | |
tree | dcb49f8af251e5dbaf9cb102b6951b320cfc4a89 /numpy/core/fromnumeric.py | |
parent | 173384a6fbe3a782f52ef30a8ffdc0a315a58880 (diff) | |
download | numpy-9064d4b2a46fc8b725314e5fae191b8497fef5f6.tar.gz |
Add documentation for amin/amax.
Diffstat (limited to 'numpy/core/fromnumeric.py')
-rw-r--r-- | numpy/core/fromnumeric.py | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/numpy/core/fromnumeric.py b/numpy/core/fromnumeric.py index 0023c99f0..ed66a1ccf 100644 --- a/numpy/core/fromnumeric.py +++ b/numpy/core/fromnumeric.py @@ -1520,6 +1520,17 @@ def amax(a, axis=None, out=None): >>> np.amax(a, axis=1) array([1, 3]) + Note + ---- + NaN values are propagated, that is if at least one item is nan, the + corresponding max value will be nan as well. To ignore NaN values (matlab + behavior), please use nanmax. + + See Also + -------- + nanmax: nan values are ignored instead of being propagated + fmax: same behavior as the C99 fmax function + """ try: amax = a.max @@ -1561,6 +1572,16 @@ def amin(a, axis=None, out=None): >>> np.amin(a, axis=1) # Minima along the second axis array([0, 2]) + Note + ---- + NaN values are propagated, that is if at least one item is nan, the + corresponding min value will be nan as well. To ignore NaN values (matlab + behavior), please use nanmin. + + See Also + -------- + nanmin: nan values are ignored instead of being propagated + fmin: same behavior as the C99 fmin function """ try: amin = a.min |