Re: [ncl-talk] FillValue problem?

From: David Brown <dbrown_at_nyahnyahspammersnyahnyah>
Date: Thu Nov 12 2009 - 15:19:44 MST

Hi David,
It looks like the _FillValue values in the NetCDF file are doubles
whereas the data variables are floats. Usually NCL complains when it
encounters a _FillValue that has
a different type than the data variable it belongs to, but for some
reason it is not in this case. There is a location in the code where
NCL reads the data thinking it is float when it is actually double. I
will look into that. Anyway the reason Rick gets 0 while you got
-4.475... is simply because the Intel MAC is little-endian while the
PPC mac is big-endian.
  -dave

On Nov 12, 2009, at 2:05 PM, David B. Reusch wrote:

> Sorry, I think this one was my fault, or at least NCL was managing as
> best it can under odd conditions (although Rick Browrigg's results
> raise
> an eyebrow...). Note that the _FillValue in ncdump is "-999." where
> it
> *should* be "-999.f". For what it's worth, I created this file in
> Matlab with snctools and, apparently, didn't quite get it right.
> After
> an edit with NCO's ncatted, NCL does what I was expecting now.
>
> Dave
>
> David B. Reusch said the following on 11/12/09 3:49 PM:
>> I have run into a situation with NCL and _FillValue that completely
>> baffles me. The short version is that the _FillValue should be -999.
>> but NCL is assigning -4.4755859375 instead. I've included an ncdump,
>> the NCL script, and the script output below. I've put the netCDF
>> file
>> (sie_1973-2001.nc) in the incoming dir of ftp.cgd.ucar.edu (it's
>> about
>> 500kb). Is this a bug or am I just missing something obvious?
>> This is
>> running on a PPC Mac at OS 10.5.8 with NCL 5.1.1.
>>
>> Thanks,
>> Dave
>>
> --
> 517 Deike Building
> Earth & Environmental Systems Institute
> Penn State University
> University Park, PA 16802
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Thu Nov 12 15:19:49 2009

This archive was generated by hypermail 2.1.8 : Tue Nov 17 2009 - 17:30:50 MST