| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| | |
DEP: remove deprecated select behaviour
|
| | |
|
|\ \
| | |
| | | |
DOC: update submodule docstrings, remove info.py files
|
| |/ |
|
|/
|
|
|
| |
In wrap and clip modes ravel_multi_index crashes or gave
invalid results if input arrays were empty but the shape not.
|
| |
|
|
|
|
|
|
|
| |
Also finish the TODO about figuring out which np.lib.<submodule>'s
are public.
This is a giant mess ...
|
| |
|
| |
|
|\
| |
| | |
Mention that split() returns views into the original array
|
| |
| |
| | |
Also adds a minor code change
|
|\ \
| | |
| | | |
MAINT: Simplify lookfor function
|
| |/ |
|
|\ \
| |/
|/| |
BUG: Fix flatten_dtype so that nested 0-field structs are flattened correctly
|
| |
| |
| |
| | |
This affects the behavior of merge_arrays.
|
|\ \
| | |
| | | |
API: Do not return None from recfunctions.drop_fields
|
| |/
| |
| |
| | |
This return value was not documented and did not make any sense. There's no reason to have a special case here.
|
|\ \
| |/
|/| |
DOC: Add warning to NPV function
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The internal rate of return (irr) is defined as the rate of return
required for the net present values of a series of cashflows to be
zero. i.e the lowest rate of return required for a project to break
even.
This is currently checked by refering to the example output from
the ``irr`` and ``npv`` function documentation. This commit adds a
test to confirm the identity holds.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
``np.npv`` calculates the present value of a series of cashflows
starting in the present (t=0). Another common definition of NPV
uses the future cashflows i.e. starting at the end of the first
period.
The difference in definition can lead to confusion for users moving
between NumPy and other projects [1] and adds complexity for
maintainers [2]. This commit adds a warning to the ``npv``
function's documentation and adds an example on how to find the npv
of a project using the alternate definition.
[1] https://github.com/numpy/numpy/issue/10877
[2] https://github.com/numpy/numpy/pull/3346
|
|\ \
| | |
| | | |
BUG: fix inconsistent axes ordering for axis in function `unique`
|
| | | |
|
| | | |
|
|\ \ \
| | | |
| | | | |
BUG: Fix uint-overflow if padding with linear_ramp and negative gain
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
linspace supports non-scalar values since version 1.16. This can replace
the former _linear_ramp method.
This removes a bug in the old implementation where certain edge and
end values resulted in an integer underflow for unsigned dtypes (see
gh-14191). Protect against this regression with a new test for all
numeric dtypes.
|
|\ \ \ \
| | | | |
| | | | | |
DOC: lib: Add more explanation of the weighted average calculation.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Also removed the incorrect comment from the docstring of `numpy.ma.average`
about the imaginary part of `weights` being ignored.
|
|\ \ \ \ \
| |/ / / /
|/| | | | |
DOC: Fixed dtype docs for var, nanvar.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Docs incorrectly stated that the default output dtype was float32 when
input array is of an integer dtype. However:
```python
np.var(np.random.randint(0, 100, 1000)).dtype == np.dtype("f8")
```
|
| | | | |
| | | | |
| | | | |
| | | | | |
* Deprecate class SafeEval
|
|\ \ \ \ \
| | | | | |
| | | | | | |
MAINT: Fix behavior of structured_to_unstructured on non-trivial dtypes
|
| | |_|_|/
| |/| | |
| | | | |
| | | | | |
Fixes #13333
|
|\ \ \ \ \
| |/ / / / |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
(#14070)
* DOC:Add example to clarify "numpy.save" behavior on already unclosed file
|
| |\ \ \ \
| | | | | |
| | | | | | |
MAINT: Clearer error message while padding with stat_length=0
|
| | | |/ /
| | |/| |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Provides a clearer error message if stat_length=0 is the cause of an
exception (mean and median return nan with warnings) as well as tests
covering this behavior.
Note: This shouldn't change the behavior/API except for the content of
the raised ValueError.
|
| | |_|/
| |/| | |
|
| |/ /
| | |
| | | |
* DOC: new nan_to_num keywords are from 1.17 onwards
|
| | | |
|
| | | |
|
| |\ \
| | | |
| | | | |
BUG: Fix file-like object check when saving arrays
|
| | | | |
|
| | | |
| | | |
| | | |
| | | | |
For writing arrays, only the ``write`` method is necessary.
|
| |\ \ \
| | |/ /
| |/| | |
BUG, DOC: add new recfunctions to `__all__`
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
When a buffer interface does not request a writeable buffer,
simply pass a read-only one when the warn on write flag is set.
This is to give an easier way forward with avoiding the deprecation
warnings: Simply do not ask for a writeable buffer.
It will break code that expects writeable buffers but does not
ask for them specifically a bit harder than would be nice.
But since such code probably should ask for it specifically, this
is likely fine (an RC release has to find out).
The main reason for this is, that this way it plays very will with
cython, which requests writeable buffers explicitly and if declared
`const` is happy about read-only (so that using `const` is the best
way to avoid the warning and makes code cleaner).
Closes gh-13929, gh-13974
|
| |/ /
| | |
| | | |
I think it should be like that (maybe I am mistaken).
|