[gradsusr] error when opening a ctl file

Jennifer Adams jma at cola.iges.org
Fri Sep 4 08:20:44 EDT 2015


GrADS doesn’t like upper case letters in the variable names, so you need to create an alias. In your descriptor file, change “EP” to “EP=>ep” and it should work just fine. The time metadata in the file may be strange (because CDO is gagging on it), but you are providing everything GrADS needs with your descriptor’s TDEF entry, so GrADS isn't looking at any time metadata in the file. 
—Jennifer


On Sep 3, 2015, at 1:09 PM, samo diatta <samo.diatta at univ-zig.sn> wrote:

> Hi everybody,
> I have a problem with interpreting my CTL file; I have a netcdf file
> with curious time format (or timestamp, see below when I use CDO) with
> ncdump I can view the time dimension; so I decide to use a ctl file to
> set the timestamp and open it with grads, unfortunately an error I
> can't understand occur when I open the ctl file (see below). Someone
> has an idea, how to solve the problem. Find attached the ctl file
> 
> ga-> open file_ERAI.ctl
> Scanning description file:  file_ERAI.ctl
> Data file ERAI.EP.1979-2013.nc is open as file 1
> LON set to 0 360
> LAT set to -89.463 89.8339
> LEV set to 1000 1000
> Time values set: 1979:1:1:0 1979:1:1:0
> E set to 1 1
> ga-> q file
> File 1 :
>  Descriptor: file_ERAI.ctl
>  Binary: ERAI.EP.1979-2013.nc
>  Type = Gridded
>  Xsize = 512  Ysize = 256  Zsize = 1  Tsize = 420  Esize = 1
>  Number of Variables = 3
>     lon  0  y,x  longitude
>     lat  0  y,x  latitude
>     ep  0  t,y,x  Budget Evaporation minus Precipitation
> ga-> d ep
> Error: Variable ep not in netcdf file
> Data Request Error:  Error for variable 'ep'
>  Error ocurred at column 1
> DISPLAY error:  Invalid expression
>  Expression = ep
> .................. ncdump gives :
> ncdump -h ERAI.EP.1979-2013.nc
> netcdf ERAI.EP.1979-2013 {
> dimensions:
> 	time = 420 ;
> 	lat = 256 ;
> 	lon = 512 ;
> variables:
> 	float EP(time, lat, lon) ;
> 		EP:units = "kg/m2/s" ;
> 		EP:long_name = "Budget Evaporation minus Precipitation" ;
> 		EP:_FillValue = 1.e+20f ;
> 	double time(time) ;
> 		time:calendar = "standard" ;
> 	float lat(lat) ;
> 		lat:La1 = 89.463f ;
> 		lat:Lo1 = 0.f ;
> 		lat:La2 = -89.463f ;
> 		lat:Lo2 = 359.297f ;
> 		lat:Di = 0.7031252f ;
> 		lat:N = 128.f ;
> 		lat:units = "degrees_north" ;
> 		lat:GridType = "Gaussian Latitude/Longitude Grid (Quasi-Regular)" ;
> 		lat:long_name = "latitude" ;
> 	float lon(lon) ;
> 		lon:La1 = 89.463f ;
> 		lon:Lo1 = 0.f ;
> 		lon:La2 = -89.463f ;
> 		lon:Lo2 = 359.297f ;
> 		lon:Di = 0.7031252f ;
> 		lon:N = 128.f ;
> 		lon:units = "degrees_east" ;
> 		lon:GridType = "Gaussian Latitude/Longitude Grid (Quasi-Regular)" ;
> 		lon:long_name = "longitude" ;
> }
> ............. and
> CDO showdate ERAI.EP.1979-2013.nc
> arning (splitTimevalue) : Reset wrong date/time to 0019-01-01 00:00:00!
>  0019-01-01  0019-01-02  0019-01-03  0019-01-04  0019-01-05
> 0019-01-06  0019-01-07  0019-01-08  0019-01-09  0019-01-10  0019-01-11
> 0019-01-12  0019-01-01  0019-01-02  0019-01-03  0019-01-04
> 0019-01-05  0019-01-06  0019-01-07  0019-01-08  0019-01-09  0019-01-10
> .......................................................
> <file_ERAI.ctl>_______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr

--
Jennifer M. Adams
Center for Ocean-Land-Atmosphere Studies (COLA)
111 Research Hall, Mail Stop 2B3
George Mason University
4400 University Drive
Fairfax, VA 22030 





-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20150904/b89e4299/attachment.html 


More information about the gradsusr mailing list