[Numpy-discussion] question about a data structure
Wed Jul 29 16:54:24 CDT 2009
Robert Kern wrote:
> 2009/7/29 Ernest Adrogué <firstname.lastname@example.org>:
>> Now, I need to be able to differentiate between 0 and 'no data'.
>> Is it possible to do this with the standard array class?
> Not really. Use masked arrays. Or use a dictionary.
masked arrays are made precisely for this. However, if you can use
floating point numbers, you could use NaN for the no data entries.
Christopher Barker, Ph.D.
Emergency Response Division
NOAA/NOS/OR&R (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception
More information about the NumPy-Discussion