-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Remove deprecated mlab code #12165
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Remove deprecated mlab code #12165
Changes from all commits
Commits
Show all changes
66 commits
Select commit
Hold shift + click to select a range
31dff4f
Remove mlab.logspace
dstansby 66f075e
Remove mlab.cohere_pairs
dstansby d6b54ab
Remove mlab.entropy
dstansby 02c939f
Remove mlab.normpdf
dstansby 0bf2b34
Remove mlab.find
dstansby 3ad4dda
Remove mlab.longest_contiguous_ones
dstansby b17ecca
Remove mlab.PCA
dstansby 61467cf
Remove mlab.prctile and mlab.prctile_rank
dstansby 4cb0ab6
Remove mlab.center_matrix
dstansby d3e2636
Remove mlab.rk4
dstansby 5966998
Remove mlab.bivariate_normal
dstansby ee38004
Remove mlab.get_xyz_where
dstansby 2792962
Remove mlab.get_sparse_matrix
dstansby 563bc0d
Remove mlab.dist, mlab.dist_point_to_segment
dstansby 3d93777
Remove mlab.griddata
dstansby 7ede68c
Remove mlab.less_simple_linear_interpolation
dstansby fb07c42
Remove mlab.slopes, mlab.stineman_interp
dstansby a0b619f
Remove mlab.segments_intersect
dstansby feeb8f7
Remove mlab.fftsurr
dstansby 5efed6c
Remove mlab.offset_line
dstansby 327a732
Remove mlab.quad2cubic
dstansby 8a7c90b
Remove mlab.path_length
dstansby c00adaf
Remove mlab.distances_along_curve
dstansby b2566e5
Remove mlab.vector_lengths
dstansby e89fe8e
Remove mlab.cross_from_above and mlab.cross_from_below
dstansby 6ae6058
Remove mlab.contiguous_regions
dstansby d0bda5e
Remove mlab.is_closed_polygon
dstansby f4b13e9
Remove mlab.poly_between
dstansby 2c861a3
Remove mlab.poly_below
dstansby 3d8bce1
Remove mlab.inside_poly
dstansby f882efd
Remove mlab.rec2csv
dstansby f1c3ee3
Remove mlab.rec2txt
dstansby e6345ea
Remove mlab.csvformat_factory
dstansby 52b55de
Remove mlab.get_formatd
dstansby 197228d
Remove mlab.FormatDatetime
dstansby ff137b6
Remove mlab.FormatDate
dstansby b542961
Remove mlab.Format... classes
dstansby 6de5073
Remove mlab.recs_join
dstansby be0ddca
Remove mlab.rec_join
dstansby 5b11761
Remove mlab.rec_summarize
dstansby 7474746
Remove mlab.rec_groupby
dstansby 7c7d859
Remove mlab.rec_keep_fields
dstansby afcb2b6
Remove mlab.rec_drop_fields
dstansby ac0fc08
Remove mlab.rec_append_fields
dstansby 9aaf9fc
Remove mlab.exp_safe
dstansby 7d31ed2
Remove mlab.amap
dstansby 2821f1b
Remove mlab.rms_flat
dstansby 8f9b0c6
Remove mlab.l1norm
dstansby c26f1d6
Remove mlab.l2norm
dstansby 2d15f21
Remove mlab.norm_flat
dstansby 00cace4
Remove mlab.frange
dstansby 9b81fd2
Remove mlab.identity
dstansby 22fe034
Remove mlab.base_repr
dstansby f336729
Remove mlab.log2
dstansby 76864f0
Remove mlab.binary_repr
dstansby a934ad8
Remove mlab.ispower2
dstansby dedc269
Remove mlab.isvector
dstansby 2157968
Remove mlab.movavg
dstansby 8e7eea0
Remove mlab.safe_isinf, mlab.safe_isnan
dstansby 872e93e
Clean up code listing
dstansby 5ea3cf3
Clean up the top of mlab
dstansby 2ca407f
Make mlab.csv2rec private
dstansby ddf38fe
Add pylab api changes
dstansby 0466b93
Move methods to functions in poly_editor.py
dstansby 89cf598
Copy in kwarg definitions to pyplot.plotfile
dstansby ca54244
Add missing alternatives
dstansby File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
Removal of deprecated :mod:`matplotlib.mlab` code | ||
------------------------------------------------- | ||
|
||
Lots of code inside the :mod:`matplotlib.mlab` module which was deprecated | ||
in Matplotlib 2.2 has been removed. See below for a list: | ||
|
||
- ``mlab.exp_safe`` (use `numpy.exp` instead) | ||
- ``mlab.amap`` | ||
- ``mlab.logspace`` (use `numpy.logspace` instead) | ||
- ``mlab.rms_flat`` | ||
- ``mlab.l1norm`` (use ``numpy.linalg.norm(a, ord=1)`` instead) | ||
- ``mlab.l2norm`` (use ``numpy.linalg.norm(a, ord=2)`` instead) | ||
- ``mlab.norm_flat`` (use ``numpy.linalg.norm(a.flat, ord=2)`` instead) | ||
- ``mlab.frange`` (use `numpy.arange` instead) | ||
- ``mlab.identity`` (use `numpy.identity` instead) | ||
- ``mlab.base_repr`` | ||
- ``mlab.binary_repr`` | ||
- ``mlab.ispower2`` | ||
- ``mlab.log2`` (use `numpy.log2` instead) | ||
- ``mlab.isvector`` | ||
- ``mlab.movavg`` | ||
- ``mlab.safe_isinf`` (use `numpy.isinf` instead) | ||
- ``mlab.safe_isnan`` (use `numpy.isnan` instead) | ||
- ``mlab.cohere_pairs`` (use `scipy.signal.coherence` instead) | ||
- ``mlab.entropy`` (use `scipy.stats.entropy` instead) | ||
- ``mlab.normpdf`` (use `scipy.stats.norm.pdf` instead) | ||
- ``mlab.find`` (use ``np.nonzero(np.ravel(condition))`` instead) | ||
- ``mlab.longest_contiguous_ones`` | ||
- ``mlab.longest_ones`` | ||
- ``mlab.PCA`` | ||
- ``mlab.prctile`` (use `numpy.percentile` instead) | ||
- ``mlab.prctile_rank`` | ||
- ``mlab.center_matrix`` | ||
- ``mlab.rk4`` (use `scipy.integrate.ode` instead) | ||
- ``mlab.bivariate_normal`` | ||
- ``mlab.get_xyz_where`` | ||
- ``mlab.get_sparse_matrix`` | ||
- ``mlab.dist`` (use `numpy.hypot` instead) | ||
- ``mlab.dist_point_to_segment`` | ||
- ``mlab.griddata`` (use `scipy.interpolate.griddata`) | ||
- ``mlab.less_simple_linear_interpolation`` (use `numpy.interp`) | ||
- ``mlab.slopes`` | ||
- ``mlab.stineman_interp`` | ||
- ``mlab.segments_intersect`` | ||
- ``mlab.fftsurr`` | ||
- ``mlab.offset_line`` | ||
- ``mlab.quad2cubic`` | ||
- ``mlab.vector_lengths`` | ||
- ``mlab.distances_along_curve`` | ||
- ``mlab.path_length`` | ||
- ``mlab.cross_from_above`` | ||
- ``mlab.cross_from_below`` | ||
- ``mlab.contiguous_regions`` (use `.cbook.contiguous_regions` instead) | ||
- ``mlab.is_closed_polygon`` | ||
- ``mlab.poly_between`` | ||
- ``mlab.poly_below`` | ||
- ``mlab.inside_poly`` | ||
- ``mlab.csv2rec`` | ||
- ``mlab.rec2csv`` (use `numpy.recarray.tofile` instead) | ||
- ``mlab.rec2text`` (use `numpy.recarray.tofile` instead) | ||
- ``mlab.rec_summarize`` | ||
- ``mlab.rec_join`` | ||
- ``mlab.recs_join`` | ||
- ``mlab.rec_groupby`` | ||
- ``mlab.rec_keep_fields`` | ||
- ``mlab.rec_drop_fields`` | ||
- ``mlab.rec_append_fields`` | ||
- ``mlab.csvformat_factory`` | ||
- ``mlab.get_formatd`` | ||
- ``mlab.FormatDatetime`` (use `datetime.datetime.strftime` instead) | ||
- ``mlab.FormatDate`` (use `datetime.date.strftime` instead) | ||
- ``mlab.FormatMillions``, ``mlab.FormatThousands``, ``mlab.FormatPercent``, | ||
``mlab.FormatBool``, ``mlab.FormatInt``, ``mlab.FormatFloat``, | ||
``mlab.FormatFormatStr``, ``mlab.FormatString``, ``mlab.FormatObj`` | ||
- ``mlab.donothing_callback`` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
Removal of deprecated :mod:`matplotlib.pylab` code | ||
-------------------------------------------------- | ||
|
||
Lots of code inside the :mod:`matplotlib.mlab` module which was deprecated | ||
in Matplotlib 2.2 has been removed. This means the following functions are | ||
no longer available in the `matplotlib.pylab` module: | ||
|
||
- ``amap`` | ||
- ``base_repr`` | ||
- ``binary_repr`` | ||
- ``bivariate_normal`` | ||
- ``center_matrix`` | ||
- ``csv2rec`` (use `numpy.recarray.tofile` instead) | ||
- ``dist`` (use `numpy.hypot` instead) | ||
- ``dist_point_to_segment`` | ||
- ``distances_along_curve`` | ||
- ``entropy`` (use `scipy.stats.entropy` instead) | ||
- ``exp_safe`` (use `numpy.exp` instead) | ||
- ``fftsurr`` | ||
- ``find`` (use ``np.nonzero(np.ravel(condition))`` instead) | ||
- ``frange`` (use `numpy.arange` instead) | ||
- ``get_sparse_matrix`` | ||
- ``get_xyz_where`` | ||
- ``griddata`` (use `scipy.interpolate.griddata` instead) | ||
- ``identity`` (use `numpy.identity` instead) | ||
- ``inside_poly`` | ||
- ``is_closed_polygon`` | ||
- ``ispower2`` | ||
- ``isvector`` | ||
- ``l1norm`` (use ``numpy.linalg.norm(a, ord=1)`` instead) | ||
- ``l2norm`` (use ``numpy.linalg.norm(a, ord=2)`` instead) | ||
- ``log2`` (use `numpy.log2` instead) | ||
- ``longest_contiguous_ones`` | ||
- ``longest_ones`` | ||
- ``movavg`` | ||
- ``norm_flat`` (use ``numpy.linalg.norm(a.flat, ord=2)`` instead) | ||
- ``normpdf`` (use `scipy.stats.norm.pdf` instead) | ||
- ``path_length`` | ||
- ``poly_below`` | ||
- ``poly_between`` | ||
- ``prctile`` (use `numpy.percentile` instead) | ||
- ``prctile_rank`` | ||
- ``rec2csv`` (use `numpy.recarray.tofile` instead) | ||
- ``rec_append_fields`` | ||
- ``rec_drop_fields`` | ||
- ``rec_join`` | ||
- ``rk4`` (use `scipy.integrate.ode` instead) | ||
- ``rms_flat`` | ||
- ``segments_intersect`` | ||
- ``slopes`` | ||
- ``stineman_interp`` | ||
- ``vector_lengths`` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does
csv2rec
have a replacement?tofile
seems like a replacement forrec2csv
notcsv2rec
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suggest using
pandas
instead. If you really need csv -> record array the best course of action is probably to vendor the code to your project.