Transforms a MaskedArray into a flexible-type array with two fields:
Returns: | record : ndarray
|
---|
Notes
A side-effect of transforming a masked array into a flexible ndarray is that meta information (fill_value, ...) will be lost.
Examples
>>> x = np.ma.array([[1,2,3],[4,5,6],[7,8,9]], mask=[0] + [1,0]*4)
>>> print x
[[1 -- 3]
[-- 5 --]
[7 -- 9]]
>>> print x.torecords()
[[(1, False) (2, True) (3, False)]
[(4, True) (5, False) (6, True)]
[(7, False) (8, True) (9, False)]]