diff options
author | Mark Wiebe <mwiebe@enthought.com> | 2011-06-27 13:13:57 -0500 |
---|---|---|
committer | Charles Harris <charlesr.harris@gmail.com> | 2011-07-06 16:24:12 -0600 |
commit | 59cdc32278ff54f3868cf0a4ee3a74943467ea7e (patch) | |
tree | dfca207e75906967e14f9d8511d613acab0b3e6f /doc/neps | |
parent | a84257505bfc5436affb3d62da0aac2038d6172e (diff) | |
download | numpy-59cdc32278ff54f3868cf0a4ee3a74943467ea7e.tar.gz |
ENH: missingdata: Add a mechanism to get masked versions of ufunc inner loops
Diffstat (limited to 'doc/neps')
-rw-r--r-- | doc/neps/missing-data.rst | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/doc/neps/missing-data.rst b/doc/neps/missing-data.rst index 6a4781f10..fabecf36e 100644 --- a/doc/neps/missing-data.rst +++ b/doc/neps/missing-data.rst @@ -354,14 +354,22 @@ Some examples:: >>> np.sum(a, skipna=True) 11.0 >>> np.mean(a) - array(NA, dtype='<f8', masked=True) - >>> np.mean(a) + NA('<f8') + >>> np.mean(a, skipna=True) 3.6666666666666665 + >>> a = np.array([np.NA, np.NA], dtype='f8', masked=True) >>> np.sum(a, skipna=True) 0.0 >>> np.max(a, skipna=True) array(NA, dtype='<f8', masked=True) + >>> np.mean(a) + NA('<f8') + >>> np.mean(a, skipna=True) + /home/mwiebe/virtualenvs/dev/lib/python2.7/site-packages/numpy/core/fromnumeric.py:2374: RuntimeWarning: invalid value encountered in double_scalars + return mean(axis, dtype, out) + nan + PEP 3118 ======== |