summaryrefslogtreecommitdiff
path: root/numpy/lib
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | ENH: adds np.nancumsum and np.nancumprodPhillip J. Wolfram2016-03-242-16/+245
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This PR adds an implementation of `nancumsum` and `nancumprod`. The actual function is a two-liner adapted from `nansum`. Its structure is adapted from PR: https://github.com/numpy/numpy/pull/5418/
* | | | TST: check reference counts of dtypes after calling bincountJaime Fernandez2016-03-211-4/+19
| | | |
* | | | Merge pull request #7341 from inesw/bug-fix-6469Charles Harris2016-03-171-0/+6
|\ \ \ \ | | | | | | | | | | TST: Add test for #6469
| * | | | TST: test for #6469Ines Wichert2016-02-291-0/+6
| | | | |
* | | | | BUG: Ongoing fixes to PR#7416Joseph Fox-Rabinovitz2016-03-162-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | Removed superfluous `ceil` call in automated bin width estimator. Updated tests to reflect modified estimator.
* | | | | DOC: Updated documentation to reflect changes to bin estimators.Joseph Fox-Rabinovitz2016-03-161-26/+40
| | | | | | | | | | | | | | | | | | | | | | | | | Described ad nauseum the relationship between `range` parameter and bin estimation. Updated formulas for estimators now that they are returning bin widths.
* | | | | BUG: Incorrect handling of range in `histogram` with automatic bins.Joseph Fox-Rabinovitz2016-03-162-77/+82
| |/ / / |/| | | | | | | | | | | | | | | Fixes #7411. Tests and documentation updated. Fixes other small issues with range and bin count computations.
* | | | BUG: Fix string copying for np.placegfyoung2016-03-152-1/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes bug in string copying in np.place in which replacements strings that were smaller than their replaced elements would only partially replace the element instead of the entire element. Closes gh-6974. Addendum: this commit also appears to have fixed issue with overflow for very large input arrays. Closes gh-7207.
* | | | Merge pull request #7414 from charris/tweak-corrcoefCharles Harris2016-03-142-8/+37
|\ \ \ \ | | | | | | | | | | Tweak corrcoef
| * | | | TST: Check that result of corrcoef are clipped.Charles Harris2016-03-131-3/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This doesn't actually test much, as we don't have any inputs where that was not already the case. But at least it is there and perhaps a fuzz test can be added at a later date.
| * | | | MAINT/BUG: Clip real and imag parts of corrcoef return to [-1, 1].Charles Harris2016-03-131-5/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The non-nan elements of the result of corrcoef should satisfy the inequality abs(x) <= 1 and the non-nan elements of the diagonal should be exactly one. We can't guarantee those results due to roundoff, but clipping the real and imaginary parts to the interval [-1, 1] improves things to a small degree. Closes #7392.
| * | | | ENH: Check array dimensionality in cov function.Charles Harris2016-03-131-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | The input arrays are documented to have ndim <=2, so check for that and raise a ValueError on failure.
* | | | | Merge pull request #7346 from erensezener/generalized_flipCharles Harris2016-03-123-5/+160
|\ \ \ \ \ | |/ / / / |/| | | / | | |_|/ | |/| | Generalized flip
| * | | ENH: Add generalized flip function and its testsEren Sezener2016-03-123-5/+160
| |/ /
* | | DOC: fix typoSamuel St-Jean2016-03-091-1/+1
| | | | | | | | | Found this while reading a docstring.
* | | MAINT: cleanup np.averageAllan Haldane2016-03-072-8/+36
| | |
* | | Merge pull request #7366 from gkBCCN/bug-fix-6542-reloadedCharles Harris2016-03-021-1/+28
|\ \ \ | | | | | | | | TST: fix #6542, add tests to check non-iterable argument raises in hstack and related functions.
| * | | TST: Fix #6542: Add tests for non-iterable input...gkBCCN2016-02-291-1/+28
| | | | | | | | | | | | | | | | | | | | | | | | ...to hstack, vstack, stack, hsplit, vsplit, dsplit, dstack that check that they raise exceptions.
* | | | BUG: np.irr should return NaN if there are no real solutionsSimon Gibbons2016-02-292-2/+7
|/ / /
* | | BUG: constant padding expected wrong type in constant_valueschiffa2016-02-271-1/+1
| | | | | | | | | | | | | | | Constant padding on 4 sides of a 2d array expected a numpy ndarray, and not a ndarray like (tuple, list, ...) Detailed description is in the issue #7353
* | | TST: added a test for constant padding on 4 sides of a 2d arraychiffa2016-02-271-0/+13
| | | | | | | | | | | | This test exposes padding bug described in the issue #7353
* | | Maint: Removed extra space from `ureduce` Mad Physicist2016-02-261-1/+1
| | | | | | | | | This is just me being OCD. I am not sure this even merits a full commit, much less a PR, but here goes anyway.
* | | DOC: Fix more typos in docs and comments.Dongjoon Hyun2016-02-251-2/+2
|/ /
* | Merge pull request #7199 from madphysicist/histogram-estimator-dictNathaniel J. Smith2016-02-231-126/+183
|\ \ | | | | | | MAINT: Cleanup for histogram bin estimator selection
| * | MAINT: Cleanup for histogram bin estimator selectionJoseph Fox-Rabinovitz2016-02-161-126/+183
| | | | | | | | | | | | | | | | | | Private function with superfluous checks was removed. Estimator Estimator functions are now semi-public and selection is simplified within histogram itself.
* | | TST: Fixed shuffle axis in tests.Joseph Fox-Rabinovitz2016-02-222-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | Since shuffle only works along the first dimension, it must be done before reshape to get reasonable looking data. Did not affect the current tests. I noticed while working on some scipy code. Also, made a couple of doc changes to np.random.shuffle.
* | | BUG: Preserve array order in np.deletegfyoung2016-02-192-4/+14
| | | | | | | | | | | | Closes gh-7113.
* | | BUG: Make returned unravel_index arrays writeablegfyoung2016-02-181-0/+6
| | | | | | | | | | | | Closes gh-7269.
* | | DOC: apply_along_axis missing whitespace inserted before colonMichael Seifert2016-02-181-1/+1
| | | | | | | | | | | | | | | The missing whitespace lead to inconsistent rendering in the online documentation. [ci skip]
* | | DOC: rewrite stack/concatenate reference in h/v/dstackAuke Wiggers2016-02-161-2/+2
| | |
* | | DOC: note in h/v/dstack points users to stack/concatenateauke2016-02-151-0/+4
|/ /
* | ENH: Adding support to the range keyword for estimation of the optimal ↵Varun Nayyar2016-02-132-3/+54
| | | | | | | | number of bins and associated tests
* | Merge pull request #7105 from seberg/writeable-as-stridedNathaniel J. Smith2016-02-132-3/+79
|\ \ | | | | | | DEP: Deprecate as_strided returning a writable array as default
| * | DOC: Add documentation for as_stridedSebastian Berg2016-02-132-3/+79
| | |
| * | DOC: Removed residual merge markup from previous commitMad Physicist2016-02-131-6/+0
| | |
* | | DOC: fix up invalid LaTeX in histogram docstring.Ralf Gommers2016-02-131-20/+24
| | |
* | | DOC: fix a number of reST formatting issues in docstrings.Ralf Gommers2016-02-131-2/+2
| | |
* | | Added 'doane' and 'sqrt' estimators to np.histogram in numpy.function_baseJoseph Fox-Rabinovitz2016-02-113-118/+206
|/ /
* | MAINT: Made `iterable` return a booleanJoseph Fox-Rabinovitz2016-02-101-8/+8
| |
* | Merge pull request #7133 from yarikoptic/bf-savezNathaniel J. Smith2016-02-091-1/+7
|\ \ | | | | | | savez: temporary file alongside with target file and improve exception message upon IOError
| * | BF: Since savez could be used with BytesIO - check if file is a stringYaroslav Halchenko2016-01-281-2/+2
| | |
| * | ENH: catch and rethrow exception in _savez upon IOError with filename infoYaroslav Halchenko2016-01-271-0/+2
| | |
| * | ENH: for savez create temporary file alongside with the target fileYaroslav Halchenko2016-01-271-1/+5
| | | | | | | | | | | | Closes: gh-5336
* | | BUG: many functions silently drop `keepdims` kwargThomas A Caswell2016-02-071-39/+106
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | change test from `type(a) is not mu.ndarray` to `not isinstance(a, mu.ndarray)` Because every sub-class of ndarray is not guaranteed to implement `keepdims` as a kwarg, when wrapping these methods care must be taken. The previous behavior was to silently eat the kwarg when dealing with a sub-class of ndarray. Now, if `keepdims=np._NoValue` (the new default) it is not passed through to the underlying function call (so the default value of `keepdims` is now controlled by the sub-class). If `keepdims` is not `np._NoValue` then it is passed through and will raise an exception if the sub-class does not support the kwarg. A special case in nanvar was required to deal with `matrix` that previously relied on `fromnumeric` silently dropping `keepdims`.
* | | Merge pull request #7181 from madphysicist/doc-typosCharles Harris2016-02-073-136/+147
|\ \ \ | | | | | | | | DOC: Updated minor typos in function_base.py and test_function_base.py
| * | | DOC: Updated minor typos in function_base.py and test_function_base.pyJoseph Fox-Rabinovitz2016-02-053-136/+147
| | | |
* | | | Merge pull request #7180 from madphysicist/nanpercentile-dimsCharles Harris2016-02-052-2/+6
|\ \ \ \ | | | | | | | | | | BUG: Fixed previous attempt to fix dimension mismatch in nanpercentile
| * | | | BUG: Fixed previous attempt to fix dimension mismatch in nanpercentileJoseph Fox-Rabinovitz2016-02-052-2/+6
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | nanpercentile was conforming to dimension convention of percentile incorrectly. percentile outputs results for the different percentiles along the first dimension of the output. nanpercentile was moving the reduction axis to the front using swapaxes, which would move the first axis out of place if there were more than two in the array. Added a test with more than two axes to demonstrate and used rollaxis instead of swapaxes to do the interhange.
* | | | MAINT: Removed supurious assert in histogram estimatorsJoseph Fox-Rabinovitz2016-02-051-3/+0
|/ / /
* | | ENH: usecols now accepts an int when only one column has to be readI--P2016-02-012-5/+68
| | |