diff options
Diffstat (limited to 'numpy/polynomial/polyutils.py')
-rw-r--r-- | numpy/polynomial/polyutils.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/numpy/polynomial/polyutils.py b/numpy/polynomial/polyutils.py index 0edaeba38..e81275e91 100644 --- a/numpy/polynomial/polyutils.py +++ b/numpy/polynomial/polyutils.py @@ -65,6 +65,15 @@ class PolyBase(object) : pass # +# We need the any function for python < 2.5 +# +def any(iterable) : + for element in iterable: + if element : + return True + return False + +# # Helper functions to convert inputs to 1d arrays # def trimseq(seq) : |