[gradsusr] Problem Displaying Templated Multiple File Data

Jennifer Adams jma at cola.iges.org
Tue Aug 30 18:31:18 EDT 2011


Glad to hear it is working. Just for the record, the third argument to  
the UNPACK entry is not necessary, the two attribute names are all you  
need. --Jennifer

On Aug 30, 2011, at 5:52 PM, Stephen McMillan wrote:

> Hi Jennifer,
>
> I did a "q attr" check on the 1948 file and found this:
> air Float32 add_offset 512.81
> air Float32 scale_factor 0.01
>
> Trying to follow example in the GrADS documentation and a few trial- 
> and-error runs, here's my revised descriptor:
>
> DSET h:\cdf\dailymeans\air.sig995.%y4.nc
> TITLE Daily Air Temperature Sig995 01Jan1948-current
> DTYPE netcdf
> OPTIONS template yrev
> UNDEF -9.99e+33
> UNPACK scale_factor add_offset 512.81
> XDEF 144 linear 0 2.5
> YDEF 73 linear -90 2.5
> ZDEF 1 linear 0 1
> TDEF 3653 linear 01jan1948 1dy
> VARS 1
> air=>tmp 0 t,y,x  Mean Daily Air Temperature at sigma level 995 (degK)
> ENDVARS
>
> Initially, after re-running, the numbers looked "okay" (a reasonable  
> range) but I noticed they were upside-down mirror images of what I  
> got using yearly files separately.  So I added the "yrev" OPTIONS  
> keyword and that appears to have fixed it.
>
> I believe everything works correctly now, so thanks for pointing me  
> in the right direction!
>
> Stephen McMillan
>
>
> On Tue, Aug 30, 2011 at 4:40 PM, Jennifer Adams <jma at cola.iges.org>  
> wrote:
> Looks like you need the UNPACK entry in your descriptor file. Check  
> your netcdf files for scale_factor and add_offset attributes.
> --Jennifer
>
> On Aug 30, 2011, at 4:31 PM, Stephen McMillan wrote:
>
>> I am having a problem correctly displaying multiple file data using  
>> a template control file.  My objective is to open, for example, the  
>> set of daily air temperature data files (in yearly files) from 1948  
>> to current as a single file, then display/analyze the data as  
>> needed without having to open each file separately.  Contents of  
>> control file (air.sig995.daily.1948-.ctl):
>>
>> DSET h:\cdf\dailymeans\air.sig995.%y4.nc
>> TITLE Daily Air Temperature Sig995 01Jan1948-current
>> DTYPE netcdf
>> OPTIONS template
>> UNDEF -9.99e+33
>> XDEF 144 linear 0 2.5
>> YDEF 73 linear -90 2.5
>> ZDEF 1 linear 0 1
>> TDEF 3653 linear 01jan1948 1dy
>> VARS 1
>> air=>tmp 0 t,y,x  Mean Daily Air Temperature at sigma level 995  
>> (degK)
>> ENDVARS
>>
>> For test purposes, I set TDEF to cover only the first 10 years.   
>> When I launch it in GrADS, it opens "normally" but the data  
>> displays with values much lower than expected.  Following is the  
>> GrADS session transcript:
>>
>> Grid Analysis and Display System (GrADS) Version 2.0.a7.oga.3
>> Copyright (c) 1988-2008 by Brian Doty and the
>> Institute for Global Environment and Society (IGES)
>> GrADS comes with ABSOLUTELY NO WARRANTY
>> See file COPYRIGHT for more information
>>
>> Config: v2.0.a7.oga.3 little-endian readline printim grib2 netcdf  
>> hdf4-sds hdf5
>> opendap-grids,stn athena geotiff
>> Issue 'q config' command for more information.
>> Loading User Defined Extensions table </bin/gex/udxt> ... ok.
>> GX Package Initialization: Size = 11 8.5
>> ga-> open c:\cdf\dailymeans\air.sig995.daily.1948-.ctl
>> Scanning description file:  c:\cdf\dailymeans\air.sig995.daily. 
>> 1948-.ctl
>> Data file h:\cdf\dailymeans\air.sig995.%y4.nc is open as file 1
>> LON set to 0 360
>> LAT set to -90 90
>> LEV set to 0 0
>> Time values set: 1948:1:1:0 1948:1:1:0
>> E set to 1 1
>> ga-> q ctlinfo
>> dset h:\cdf\dailymeans\air.sig995.%y4.nc
>> title Daily Air Temperature Sig995 01Jan1948-current
>> undef -9.99e+33
>> dtype netcdf
>> xdef 144 linear 0 2.5
>> ydef 73 linear -90 2.5
>> zdef 1 linear 0 1
>> tdef 3653 linear 00Z01JAN1948 1440mn
>> vars 1
>> air=>tmp  0  t,y,x  Mean Daily Air Temperature at sigma level 995  
>> (degK)
>> endvars
>> ga-> set time 25dec1953 5jan1954
>> Time values set: 1953:12:25:0 1954:1:5:0
>> ga-> d tmp-273.15
>> Contouring: -29000 to -21000 interval 1000
>> Contouring: -29000 to -21000 interval 1000
>> Contouring: -29000 to -21000 interval 1000
>> Contouring: -29000 to -21000 interval 1000
>> Contouring: -29000 to -21000 interval 1000
>> Contouring: -29000 to -21000 interval 1000
>> Contouring: -29000 to -21000 interval 1000
>> Contouring: -29000 to -21000 interval 1000
>> Contouring: -29000 to -21000 interval 1000
>> Contouring: -29000 to -21000 interval 1000
>> Contouring: -29000 to -21000 interval 1000
>> Contouring: -29000 to -21000 interval 1000
>> ga->
>> ______________________________________
>>
>> I was expecting data to display in deg C, i.e., in the range of  
>> roughly -50 to 30, which is what I would get if I open a yearly  
>> file separately.  I also noticed that the display pattern itself is  
>> not consistent with the original files' data.  The data folder  
>> contains valid yearly files from 1948 through 2011.
>>
>> I did search the gradsusr.org archives for help, but could not find  
>> a solution.  I would appreciate someone suggesting a fix.  I am  
>> using Opengrads Version 2.0.a7.oga.3 on a Windows XP.
>>
>> Stephen McMillan
>>
>> ***************************************************
>> The information contained in this e-mail message
>> is intended only for the use of the recipient(s)
>> named above and may contain information that is
>> privileged, confidential, and/or proprietary.
>> If you are not the intended recipient, you may not
>> review, copy or distribute this message. If you have
>> received this communication in error, please notify
>> the sender immediately by e-mail, and delete the original message.
>> ***************************************************
>>
>> _______________________________________________
>> gradsusr mailing list
>> gradsusr at gradsusr.org
>> http://gradsusr.org/mailman/listinfo/gradsusr
>>
>
> --
> Jennifer M. Adams
> IGES/COLA
> 4041 Powder Mill Road, Suite 302
> Calverton, MD 20705
> jma at cola.iges.org
>
>
>
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
>
>
> ***************************************************
> The information contained in this e-mail message
> is intended only for the use of the recipient(s)
> named above and may contain information that is
> privileged, confidential, and/or proprietary.
> If you are not the intended recipient, you may not
> review, copy or distribute this message. If you have
> received this communication in error, please notify
> the sender immediately by e-mail, and delete the original message.
> ***************************************************
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr

--
Jennifer M. Adams
IGES/COLA
4041 Powder Mill Road, Suite 302
Calverton, MD 20705
jma at cola.iges.org



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20110830/7b1eed36/attachment-0003.html 


More information about the gradsusr mailing list