[GRASS-user] Question about r.out.gdal (netcdf format)

Thomas Adams Thomas.Adams at noaa.gov
Fri Aug 5 18:36:37 EDT 2011


  All:

I'm successfully able to export a netcdf file from GRASS 6.4.1 using 
r.out.gdal. Using ncdump shows a reasonable result. The problem I'm 
having is that the netcdf file contains neither the data type (2-m 
temperature) nor the units (degrees Kelvin). The software I need to use 
to import the resulting netcdf file must know the data type and units in 
order to import it. How can I add these attributes to the netcdf file?

One thought I had was to use ncdump to export a cdl file and then have a 
script add the attributes I need and then use ncgen to re-generate the 
netcdf file with the data type and units attributes added.

Before I embarked on this path I thought there may be a simpler way? I 
know there are tools such as cdo and ncl, but it may be more work to 
sort-out using these than using the brute force method I'm proposing…

Regards,
Tom

-- 
Thomas E Adams
National Weather Service
Ohio River Forecast Center
1901 South State Route 134
Wilmington, OH 45177

EMAIL:	thomas.adams at noaa.gov

VOICE:	937-383-0528
FAX:	937-383-0033



More information about the grass-user mailing list