Re: [Numpy-discussion] blank values '--'

2011-02-24 Thread David Brown
Hi Bryan, By default PyNIO returns a NumPy masked array if a _FillValue attribute is found for the variable you are trying to load. It looks like Pauli Virtenen has pointed to the relevant NumPy documentation. Using masked array methods you can discover the values that are masked and print as '-

Re: [Numpy-discussion] blank values '--'

2011-02-24 Thread Benjamin Root
On Thu, Feb 24, 2011 at 12:00 PM, Bryan Woods wrote: > Hello, > > I am loading in data from the GRIB2 files using PyNIO. Once I load them > into numpy arrays I am left with a halo of values near the array boundaries > that appear to be empty. When I print them or use them in conditional > stateme

Re: [Numpy-discussion] blank values '--'

2011-02-24 Thread Pauli Virtanen
Thu, 24 Feb 2011 13:00:09 -0500, Bryan Woods wrote: [clip] > As an example if I print the array I see: > > [[-- -- -- ..., -- -- --] > [-- -- -- ..., -- -- --] > [-- -- -- ..., -- -- --] > ..., > [-- -- -- ..., -- -- --] > [-- -- -- ..., -- -- --] > [-- -- -- ..., -- -- --]] > > thoug

[Numpy-discussion] blank values '--'

2011-02-24 Thread Bryan Woods
Hello, I am loading in data from the GRIB2 files using PyNIO. Once I load them into numpy arrays I am left with a halo of values near the array boundaries that appear to be empty. When I print them or use them in conditional statements I see values of '--'. I'd like to turn these values into