summaryrefslogtreecommitdiff
path: root/numpy/lib
Commit message (Collapse)AuthorAgeFilesLines
* MAINT: Rename function to prevent name-shadowingEric Wieser2017-03-231-3/+4
| | | | | This file had two functions called flatten_dtype, which did similar but different things.
* DOC: There's a name for {False, True}, and it's "bool"Eric Wieser2017-03-231-2/+3
|
* DOC: Include np. prefix in meshgrid examplesEgor Klenin2017-03-211-5/+5
| | | | Add "np." prefix to meshgrid calls for consistency
* Merge pull request #8762 from eric-wieser/poly1d-fixesCharles Harris2017-03-142-29/+54
|\ | | | | BUG: Prevent crash in poly1d.__eq__
| * DEP: Deprecate copying random properties in __init__Eric Wieser2017-03-091-2/+9
| |
| * MAINT: Remove weird __setattr__ logic emulating propertiesEric Wieser2017-03-091-27/+32
| | | | | | | | | | Presumably written long before @property existed. This means we don't need __dict__ everywhere
| * BUG: Prevent crash in poly1d.__eq__Eric Wieser2017-03-092-0/+13
| | | | | | | | Fixes #8760
* | Merge pull request #8750 from warut-vijit/masterEric Wieser2017-03-082-1/+8
|\ \ | |/ |/| BUG: Fix np.average for object arrays
| * BUG: Fix np.average with object array weightsDuke Vijitbenjaronk2017-03-072-1/+8
| | | | | | | | Fixes #8696
* | BUG: Make MaskedArray.argsort and MaskedArray.sort consistentEric Wieser2017-03-071-0/+12
|/ | | | | | | Previously, these had different rules for unmasking values, and even different arguments to decide how to do so. Fixes #8664
* DOC: Fixed small mistakes in numpy.copy documentation.Michael Seifert2017-02-261-68/+68
| | | | | | | Including missing backticks around link, included a missing colon in example and removed excessive indentation before "doctest skip directive". [skip ci]
* Merge pull request #8685 from eric-wieser/shape-to-ndimJulian Taylor2017-02-257-17/+17
|\ | | | | ENH: add dtype.ndim
| * MAINT: replace len(x.shape) with x.ndimEric Wieser2017-02-247-17/+17
| |
* | Merge pull request #8688 from madphysicist/patch-1Charles Harris2017-02-241-1/+8
|\ \ | | | | | | DOC: Added note to np.diff
| * | DOC: Added note to np.diffJoseph Fox-Rabinovitz2017-02-241-1/+8
| |/ | | | | | | Also noted that type is preserved. [ci skip]
* | MAINT: Fix use of Python 2.6 deprecated escape sequences.Charles Harris2017-02-241-2/+2
|/ | | | Closes #8687.
* Merge pull request #8646 from joshloyal/enh-inplace-nan_to_numEric Wieser2017-02-242-2/+19
|\ | | | | ENH: Allow for an in-place nan_to_num conversion
| * ENH: Allow for an in-place nan_to_num conversion. Fixes #8634Joshua Loyal2017-02-202-2/+19
| |
* | Merge pull request #8677 from eric-wieser/use-izip_longestJulian Taylor2017-02-231-13/+9
|\ \ | | | | | | MAINT: We can now rely on itertools.izip_longest existing
| * | MAINT: We can now rely on itertools.izip_longest existingEric Wieser2017-02-231-13/+9
| | |
* | | Merge pull request #8668 from flying-sheep/patch-1Eric Wieser2017-02-221-2/+9
|\ \ \ | | | | | | | | DOC: Add more examples for np.c_
| * | | DOC: Added “See Also” section for c_Philipp A2017-02-221-2/+5
| | | |
| * | | DOC: Added more common example for np.c_Philipp A2017-02-221-0/+4
| |/ / | | | | | | | | | I mostly use that object to bind 1D arrays as columns, so I added an example for that use case.
* | | ENH: gradient support for unevenly spaced dataAlessandro Pietro Bardelli2017-02-222-126/+398
|/ / | | | | | | | | | | | | | | | | | | | | | | | | This somehow reverts #7618 and solves #6847, #7548 by implementing support for unevenly spaced data. Now the behaviour is similar to that of Matlab/Octave function. As argument it can take: 1. A single scalar to specify a sample distance for all dimensions. 2. N scalars to specify a constant sample distance for each dimension. i.e. `dx`, `dy`, `dz`, ... 3. N arrays to specify the coordinates of the values along each dimension of F. The length of the array must match the size of the corresponding dimension 4. Any combination of N scalars/arrays with the meaning of 2. and 3.
* | MAINT: Be specific about where AxisError is raisedEric Wieser2017-02-201-2/+2
| | | | | | | | These were tested by temporarily removing the base classes from AxisError
* | MAINT: Use normalize_axis_index in all python axis checkingEric Wieser2017-02-202-15/+7
| | | | | | | | | | | | | | As a result, some exceptions change from ValueError to IndexError This also changes the exception types raised in places where normalize_axis_index is not quite appropriate
* | Merge pull request #8638 from juliantaylor/packbits-fixCharles Harris2017-02-191-0/+9
|\ \ | |/ |/| BUG: fix wrong odd determination in packbits
| * BUG: fix wrong odd determination in packbitsJulian Taylor2017-02-191-0/+9
| | | | | | | | closes gh-8637
* | Merge pull request #8633 from MSeifert04/boolean_arrays_in_ix__funcEric Wieser2017-02-191-1/+14
|\ \ | | | | | | DOC: Mention boolean arrays in the ix_ documentation.
| * | DOC: Mention boolean arrays in the ix_ documentation.Michael Seifert2017-02-181-1/+14
| | |
* | | Merge pull request #8631 from anntzer/fill_diagonal-typoEric Wieser2017-02-191-2/+2
|\ \ \ | |_|/ |/| | Fix typo in fill_diagonal docstring.
| * | DOC: Fix typo in fill_diagonal docstring.Antony Lee2017-02-181-2/+2
| |/
* | Merge pull request #8614 from eric-wieser/apply_along_axis-emptyMarten van Kerkwijk2017-02-182-1/+23
|\ \ | |/ |/| BUG: Don't leak internal exceptions when given an empty array
| * BUG: Don't leak internal exceptions when given an empty arrayEric Wieser2017-02-132-1/+23
| | | | | | | | Fixes #7454
* | Merge pull request #8617 from eric-wieser/fix-8561Marten van Kerkwijk2017-02-144-12/+19
|\ \ | | | | | | BUG: Copy meshgrid after broadcasting
| * | BUG: The broadcast shape of no things should be (), not ValueErrorEric Wieser2017-02-132-2/+2
| | |
| * | BUG: Copy meshgrid after broadcasting, fixing #8561Eric Wieser2017-02-132-10/+17
| |/ | | | | | | Also, remove some unused variables
* | DOC: Indicate that axis param to average may be a tuple of ints.Alex Rothberg2017-02-121-3/+10
|/
* Revert "DOC: gradient uses 1st order central difference in the interior"Alessandro Pietro Bardelli2017-02-121-3/+3
|
* Merge pull request #8441 from eric-wieser/apply_along_axis-ndStephan Hoyer2017-02-112-68/+157
|\ | | | | BUG: Fix crash on 0d return value in apply_along_axis
| * MAINT: Improve error-checking of axis argumentEric Wieser2017-02-111-3/+2
| | | | | | | | Copied from the implementation in core.shape_base.stack
| * TST: Verify apply_along_axis now works on masked arraysEric Wieser2017-02-111-0/+14
| | | | | | | | | | Note that this is not a full subsitute for np.ma.apply_along_axis, as that allows functions to return a mix of np.ma.masked and scalars
| * MAINT: Transpose the result, rather than working with a transposed viewEric Wieser2017-02-111-23/+34
| | | | | | | | | | | | | | .transpose does not specify that it must return a view, so subclasses (like np.ma.array) could otherwise break this. This exposes some more need for matrix special casing.
| * BUG: Work around evil matrix.__array_prepare__Eric Wieser2017-02-112-4/+15
| |
| * BUG: Call __array_prepare__ before __array_wrap__Eric Wieser2017-02-111-1/+4
| |
| * MAINT: Use np.ndindex, which seems just as efficientEric Wieser2017-02-111-18/+8
| |
| * BUG: Fix crash on 0d return value in apply_along_axisEric Wieser2017-02-112-64/+125
| | | | | | | | | | | | Also: ENH: Support arbitrary dimensionality of return value MAINT: remove special casing
* | DOC: gradient uses 1st order central difference in the interior (#8605)drabach2017-02-111-3/+3
| | | | | | The gradient function uses 1st order central difference in the interior, not second order.
* | BUG: Make iscomplexobj compatible with custom dtypes againJoerg Behrmann2017-02-102-5/+12
|/ | | | | | | | | This change makes iscomplexobj compatible with custom array types using custom dtypes, that are not fully compatible to Numpys dtypes, which can nevertheless be coerced to a numpy array with asarray again, as has been the behaviour before PR #7936. Fixes #8601
* MAINT: Remove __setslice__ and __getslice__Eric Wieser2017-02-092-13/+0
| | | | | This code was only here for Python 2.5 compatibility, but numpy requires 2.7 at minimum