| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| | |
DOC: clear up warnings, fix matplotlib plot
|
| | |
|
|/
|
|
| |
Closes #10847
|
| |
|
|\
| |
| | |
BUG: fix complex casting error in cov with aweights
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When using cov with a complex input and with aweights specified, cov
will error as a result of trying to cast a complex value into a float64.
This comes about since average is used to calculate the sum of the
weights from aweights. average returns the sum of weights as the same
type as its result, not the weights type. For a complex input m, and
any type for aweights, this would result in a complex value for fact.
It appears the primary purpose of np.float64(fact) is to provide a NaN
value from the divide when fact is an integer zero. This has been
replaced by using numpy.divide to replicate the same behavior, but to
also handle complex types.
|
|\ \
| | |
| | | |
MAINT: Stop using non-tuple indices internally
|
| |/
| |
| |
| |
| |
| | |
By not using this type of indexing, it becomes easier for subclasses to override indexing in a way that works correctly with numpy functions.
These locations were found by deprecating the behavior in question, which is deliberately not part of this commit
|
|\ \
| | |
| | | |
DOC: Add graph showing different behaviors of np.percentile
|
| | |
| | |
| | |
| | | |
With thanks to @ricardoV94 for inspiring this
|
|/ /
| |
| |
| |
| |
| |
| |
| | |
Abstract collection classes accessed from the collections module
have been deprecated since Python 3.3. They should be
accessed through collections.abc. When run with Python
3.7, the deprecation warning cause multiple tests to
fail.
|
| | |
|
| |
| |
| |
| | |
[ci-skip]
|
|\ \
| | |
| | | |
DOC: Fix incorrect formula in gradient docstring.
|
| |/ |
|
|/
|
|
|
|
|
|
|
|
| |
These are now handled generically by the underlying C function
This fixes the period argument for 0d arrays.
Now never returns a pure-python scalar, which matches the behaviour of most of numpy.
Rework of b66a200a4a1e98f1955c8a774e4ebfb4588dab5b
|
| |
|
|
|
| |
Found via `codespell`
|
|\
| |
| | |
MAINT: Avoid repeated validation of percentiles in nanpercentile
|
| |
| |
| |
| |
| |
| | |
Previously, this would check the percentiles were 0 <= q <= 100 on every single slice of non-reduction axes.
This also pulls the division by 100 to the top level, which makes things clearer, and also reduces the size of the stack trace
|
| |
| |
| | |
Found via `codespell`
|
|\ \
| | |
| | | |
MAINT: Move histogram and histogramdd into their own module
|
| |\ \
| | |/ |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
800 self-contained lines are easily enough to go in their own file, as are the 500 lines of tests.
For compatibility, the names are still available through `np.lib.function_base.histogram` and `from np.lib.function_base import *`
For simplicity of imports, all of the unqualified `np.` names are now qualified
|
| |/
|/| |
|
|/
|
|
| |
Updates the two docstrings to match.
|
| |
|
|
|
|
| |
Especially necessary given the strange heuristics that decay the number of conditions to 1
|
| |
|
|
|
|
|
|
| |
single boolean is ok
Also fix the test added in gh-4792, which didn't make sense, but passed anyway
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Split up the overloaded `bins` variable into separate names depending on its meaning
Helpful errors are now emitted for:
* non-integer bin counts (fixes gh-8072)
* non-1d bin edges
Removes another use of `np.isscalar`...
|
|\
| |
| | |
BUG: Fixes histogram monotonicity check for unsigned bin values
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| | |
Double-indexing is just a little harder to read
|
|\ \
| | |
| | | |
BUG: various fixes to np.gradient
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | | |
2d arrays would work, but in unpredictable and undocumented ways.
This at least makes gh-9401 give a better error message.
|
| | |
| | |
| | |
| | | |
This fixes gh-8292
|
| | | |
|
| | |
| | |
| | |
| | |
| | | |
Also add a hint to the documentation advising the use of moveaxis over rollaxis.
Tests for rollaxis are left alone.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This is the case for x in {int, bool, str, float, complex, object}.
Using the np.{x} version is deceptive as it suggests that there is a
difference. This change doesn't affect any external behaviour. The
`long` type is missing in python 3, so np.long is still useful
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
TST: Added tests for `n` parameter
Added test for `datetime64` type change
Added tests for axis normalization
Added test for subtype handling
DOC: Minor updates to docs:
Added explanation for `n==0`
Added documentation describing `datetime64` handling
Updated formatting
Added call to normalize_axis_index
|
| | | |
|
| |/
|/|
| |
| | |
This isn't the case for `diff`
|
| | |
|
| | |
|