8000 Merge pull request #10186 from eric-wieser/move_histogram · numpy/numpy@0bcc57a · GitHub
[go: up one dir, main page]

Skip to content

Commit 0bcc57a

Browse files
authored
Merge pull request #10186 from eric-wieser/move_histogram
MAINT: Move histogram and histogramdd into their own module
2 parents 4655d5b + ccbe65d commit 0bcc57a

File tree

6 files changed

+1352
-1313
lines changed

6 files changed

+1352
-1313
lines changed

doc/release/1.15.0-notes.rst

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,15 @@ builtin arbitrary-precision `Decimal` and `long` types.
5555
Improvements
5656
============
5757

58+
``histogram`` and ``histogramdd` functions have moved to ``np.lib.histograms``
59+
------------------------------------------------------------------------------
60+
These were originally found in ``np.lib.function_base``. They are still
61+
available under their un-scoped ``np.histogram(dd)`` names, and
62+
to maintain compatibility, aliased at ``np.lib.function_base.histogram(dd)``.
63+
64+
Code that does ``from np.lib.function_base import *`` will need to be updated
65+
with the new location, and should consider not using ``import *`` in future.
66+
5867
``MaskedArray.astype`` now is identical to ``ndarray.astype``
5968
-------------------------------------------------------------
6069
This means it takes all the same arguments, making more code written for

numpy/lib/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
from .stride_tricks import *
1515
from .twodim_base import *
1616
from .ufunclike import *
17+
from .histograms import *
1718

1819
from . import scimath as emath
1920
from .polynomial import *
@@ -43,6 +44,7 @@
4344
__all__ += npyio.__all__
4445
__all__ += financial.__all__
4546
__all__ += nanfunctions.__all__
47+
__all__ += histograms.__all__
4648

4749
from numpy.testing import _numpy_tester
4850
test = _numpy_tester().test

0 commit comments

Comments
 (0)
0