summaryrefslogtreecommitdiff
path: root/numpy/core/numeric.py
diff options
context:
space:
mode:
authorMark Wiebe <mwwiebe@gmail.com>2011-01-16 01:48:42 -0800
committerMark Wiebe <mwwiebe@gmail.com>2011-01-16 01:48:42 -0800
commit165d98d9a574aaba367f20b4fcd8dec7fda0bafb (patch)
treee95edbebc6ba31a11481974c5d50ade444338a9d /numpy/core/numeric.py
parent1604e898911755ee29f829ee2ae1ffcc80c3dade (diff)
downloadnumpy-165d98d9a574aaba367f20b4fcd8dec7fda0bafb.tar.gz
ENH: core: Switch nonzero to use the iterator as an example, add count_nonzero function
Diffstat (limited to 'numpy/core/numeric.py')
-rw-r--r--numpy/core/numeric.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/numpy/core/numeric.py b/numpy/core/numeric.py
index 62fbd4186..a65c62a08 100644
--- a/numpy/core/numeric.py
+++ b/numpy/core/numeric.py
@@ -1,6 +1,6 @@
__all__ = ['newaxis', 'ndarray', 'flatiter', 'newiter', 'nested_iters', 'ufunc',
- 'arange', 'array', 'zeros', 'empty', 'broadcast', 'dtype',
- 'fromstring', 'fromfile', 'frombuffer',
+ 'arange', 'array', 'zeros', 'count_nonzero', 'empty', 'broadcast',
+ 'dtype', 'fromstring', 'fromfile', 'frombuffer',
'int_asbuffer', 'where', 'argwhere',
'concatenate', 'fastCopyAndTranspose', 'lexsort',
'set_numeric_ops', 'can_cast',
@@ -197,6 +197,7 @@ newaxis = None
arange = multiarray.arange
array = multiarray.array
zeros = multiarray.zeros
+count_nonzero = multiarray.count_nonzero
empty = multiarray.empty
fromstring = multiarray.fromstring
fromiter = multiarray.fromiter