This changed with Numpy commit:
commit
1985497ddd1c179d5ae4b7ba061a8b8c5540f543
Author: Pauli Virtanen <pav@iki.fi>
Date: Sun Jul 18 17:17:58 2010 +0000
BUG: core: format 'nan' and 'inf' also in array repr by default (#1050)
if value == 0:
return '0'
if value == None or isnan(value):
- return 'NaN'
+ return 'nan'
if power == None: # auto-detect power
power = get_power(value)
'polymer peak 0 (N)', 'polymer peak 1 (N)', 'polymer peak 2 (N)',
'polymer peak 3 (N)', 'polymer peak 4 (N)', 'polymer peak 5 (N)']
>>> retract[:5,-2:]
-Data([[ NaN, NaN],
- [ NaN, NaN],
- [ NaN, NaN],
- [ NaN, NaN],
- [ NaN, NaN]])
+Data([[ nan, nan],
+ [ nan, nan],
+ [ nan, nan],
+ [ nan, nan],
+ [ nan, nan]])
>>> retract[1097:1103,-2:] # doctest: +ELLIPSIS
-Data([[ NaN, 5.2...e-10],
- [ NaN, 5...e-10],
- [ NaN, 6.1...e-10],
- [ NaN, 6.2...e-10],
- [ NaN, 7...e-10],
- [ NaN, NaN]])
+Data([[ nan, 5.2...e-10],
+ [ nan, 5...e-10],
+ [ nan, 6.1...e-10],
+ [ nan, 6.2...e-10],
+ [ nan, 7...e-10],
+ [ nan, nan]])
>>> retract[-5:,-2:]
-Data([[ NaN, NaN],
- [ NaN, NaN],
- [ NaN, NaN],
- [ NaN, NaN],
- [ NaN, NaN]])
+Data([[ nan, nan],
+ [ nan, nan],
+ [ nan, nan],
+ [ nan, nan],
+ [ nan, nan]])
"""