Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 5b11761

Browse files
committed
Remove mlab.rec_summarize
1 parent be0ddca commit 5b11761

2 files changed

Lines changed: 1 addition & 23 deletions

File tree

doc/api/next_api_changes/2018-09-18-DS.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ in Matplotlib 2.2 has been removed. See below for a list:
4141
- `mlab.inside_poly`
4242
- `mlab.rec2csv` (use numpy.recarray.tofile instead)
4343
- `mlab.rec2text` (use numpy.recarray.tofile instead)
44+
- `mlab.rec_summarize`
4445
- `mlab.rec_join`
4546
- `mlab.recs_join`
4647
- `mlab.csvformat_factory`

lib/matplotlib/mlab.py

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1656,29 +1656,6 @@ def rec_groupby(r, groupby, stats):
16561656
return np.rec.fromrecords(rows, names=names)
16571657

16581658

1659-
@cbook.deprecated("2.2")
1660-
def rec_summarize(r, summaryfuncs):
1661-
"""
1662-
*r* is a numpy record array
1663-
1664-
*summaryfuncs* is a list of (*attr*, *func*, *outname*) tuples
1665-
which will apply *func* to the array *r*[attr] and assign the
1666-
output to a new attribute name *outname*. The returned record
1667-
array is identical to *r*, with extra arrays for each element in
1668-
*summaryfuncs*.
1669-
1670-
"""
1671-
1672-
names = list(r.dtype.names)
1673-
arrays = [r[name] for name in names]
1674-
1675-
for attr, func, outname in summaryfuncs:
1676-
names.append(outname)
1677-
arrays.append(np.asarray(func(r[attr])))
1678-
1679-
return np.rec.fromarrays(arrays, names=names)
1680-
1681-
16821659
@cbook.deprecated("2.2")
16831660
def csv2rec(fname, comments='#', skiprows=0, checkrows=0, delimiter=',',
16841661
converterd=None, names=None, missing='', missingd=None,

0 commit comments

Comments
 (0)