Re: missing values from grib variable

From: <Oliver.Fuhrer_at_nyahnyahspammersnyahnyah>
Date: Tue, 5 May 2009 08:40:07 +0200

Wolfgang,

To my knowledge, there is no "standard" way to code a certain value as an undef value in a grib1 file. The method used is usually to code a bitmap where the data is saved in the file. So, in your case, NCL has no way of knowing which values are the undef values. Some oroginating centers (for example MeteoSwiss or DWD) have implemented their own way of coding undef values and use the local section of the grib file format for this purpose. But these are not standards. The field you are reading (leaf area index) is probably undefined over sea points. So you will either have to read tha land/sea mask and mask out sea points in your field, or you will have to set _FillValue manually to 0.

Good luck,
Oli
 
________________________________________

Oliver Fuhrer
Numerical Models

Federal Departement of Home Affairs FDHA
Federal Office of Meteorology and Climatology MeteoSwiss

Kraehbuehlstrasse 58, P.O. Box 514, CH-8044 Zurich, Switzerland

Tel. +41 44 256 93 59
Fax +41 44 256 92 78
oliver.fuhrer_at_meteoswiss.ch
www.meteoswiss.ch - First-hand information
  
 

> -----Original Message-----
> From: ncl-talk-bounces_at_ucar.edu
> [mailto:ncl-talk-bounces_at_ucar.edu] On Behalf Of Wolfgang Langhans
> Sent: Montag, 4. Mai 2009 21:40
> To: ncl-talk_at_ucar.edu
> Subject: missing values from grib variable
>
> Hi,
> I have two questions:
> 1) I read in a variable from a grib file:
> LAI_MX=f->LAI_MX_GDS10_SFC(:,:)
> where f points at the grib file. The command printVarSummary(LAI_MX)
> shows the attribute _FillValue : -999. There should actually
> be plenty
> of missing value entries in this variable, but these have the
> value zero
> instead, which is not good. How does it come that wrong missing values
> are assigned here?
>
> 2) Following option 2 for netcdf output on the webpage I export to
> netcdf format. One variable is simply a dimensionless character and I
> run into troubles, if I use getvardims:
>
> filevardef(fout,
> "rotated_pole",typeof(rotated_pole),getvardims(rotated_pole))
>
> How should I proceed here, when no dimensions need to be assigned to
> "rotated_pole"?
>
> Many thanks,
> Wolfgang
>
> ************************************************
> Wolfgang Langhans
>
> Institute for Atmospheric and Climate Science
> ETH Zürich
> Universitätstrasse 16
> CH-8092 Zürich, Switzerland
>
> e-mail: wolfgang.langhans_at_env.ethz.ch
> phone : +41 44 632 78 18
> fax : +41 44 632 13 11
> room : CHN L16.3
> web : http://www.iac.ethz.ch/people/wolangha
> ************************************************
>
>
> _______________________________________________
> 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 Tue May 05 2009 - 00:40:07 MDT

This archive was generated by hypermail 2.2.0 : Wed May 06 2009 - 16:48:59 MDT