writing grib2 to NetCDF
Heiner Körnich
heiner at MISU.SU.SE
Fri Nov 13 10:26:20 EST 2009
Hi Zilore,
on the MARS server at ECMWF you can convert the data directly to NetCDF. But
you need access to the ECMWF computer for this.
Then:
mars << EOF
retrieve,
time=00:00:00/06:00:00/12:00:00/18:00:00,
date=$iyear-$longmonth-01/to/$iyear-$longmonth-$lastday[$imonth],
stream=oper,
levtype=pl,
expver=1,
type=an,
class=ei,
param=130.128,
levelist=1/2/3/5/7/10/20/30/50/70/100/125/150/175/200/225/250/300/350/400/450/500/550/600/650/700/750/775/800/825/850/875/900/925/950/975/1000,
grid = 1.0/1.0,
target="output.grib"
EOF
mars -N <<@@
mars2netcdf,
source = output.grib,
target = $outname
ignore = TYPE/STEP
@@
Regards,
Heiner
On Fri, Nov 13, 2009 at 10:11 AM, zilore mumba <zmumba at yahoo.com> wrote:
> Dear Grads users,
> Help sought if possible.
> I have data in GRIB2 format from ECMWF. Because of the double headers in
> the data (complex packing), wgrib is not able to decode it propoerly hence
> not possible to make a ctl with grib2ctl.pl.
> What I do is to decode the data with the ECMWF GRIB_API decoder and rewrite
> it in binary for grads with fortran. This works fine. I thought another
> alternative would be to convert the GRIB2 to NetCDF.
> I have checked the listserver but did not find anything.
> Is such a conversion possible?
> Thanks for assistance
> Zilore
>
>
>
--
Heiner Körnich
Dept. of Meteorology Tel: +46 8 164333
Stockholms University, SE-106 91 Stockholm, Sweden
Email: heiner at misu.su.se www.misu.su.se/~heiner/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20091113/d0ac2276/attachment.html
More information about the gradsusr
mailing list