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

Skip to content

Commit 8e7eea0

Browse files
committed
Remove mlab.safe_isinf, mlab.safe_isnan
1 parent 2157968 commit 8e7eea0

2 files changed

Lines changed: 2 additions & 31 deletions

File tree

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

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ in Matplotlib 2.2 has been removed. See below for a list:
1919
- `mlab.log2` (use numpy.log2 instead)
2020
- `mlab.isvector`
2121
- `mlab.movavg`
22+
- `mlab.safe_isinf` (use numpy.isinf instead)
23+
- `mlab.safe_isnan` (use numpy.isnan instead)
2224
- `mlab.cohere_pairs` (use scipy.signal.coherence instead)
2325
- `mlab.entropy` (use scipy.stats.entropy instead)
2426
- `mlab.normpdf` (use scipy.stats.norm.pdf instead)

lib/matplotlib/mlab.py

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1194,37 +1194,6 @@ def cohere(x, y, NFFT=256, Fs=2, detrend=detrend_none, window=window_hanning,
11941194
return Cxy, f
11951195

11961196

1197-
# helpers for loading, saving, manipulating and viewing numpy record arrays
1198-
@cbook.deprecated("2.2", 'numpy.isnan')
1199-
def safe_isnan(x):
1200-
':func:`numpy.isnan` for arbitrary types'
1201-
if isinstance(x, str):
1202-
return False
1203-
try:
1204-
b = np.isnan(x)
1205-
except NotImplementedError:
1206-
return False
1207-
except TypeError:
1208-
return False
1209-
else:
1210-
return b
1211-
1212-
1213-
@cbook.deprecated("2.2", 'numpy.isinf')
1214-
def safe_isinf(x):
1215-
':func:`numpy.isinf` for arbitrary types'
1216-
if isinstance(x, str):
1217-
return False
1218-
try:
1219-
b = np.isinf(x)
1220-
except NotImplementedError:
1221-
return False
1222-
except TypeError:
1223-
return False
1224-
else:
1225-
return b
1226-
1227-
12281197
@cbook.deprecated("2.2")
12291198
def csv2rec(fname, comments='#', skiprows=0, checkrows=0, delimiter=',',
12301199
converterd=None, names=None, missing='', missingd=None,

0 commit comments

Comments
 (0)