[gradsusr] Serious Lterp Issue With GFS Data & Climatology Data
Eric Altshuler
ela at cola.iges.org
Tue Jan 21 23:48:35 EST 2014
Hi Aaron,
The anomaly plot looks realistic, and your script seems to be correct (there are a few redundant commands, but the result is OK).
Eric
----- Original Message -----
From: "Aaron @ LSC Perry" <Aaron.Perry at lsc.vsc.edu>
To: "GrADS Users Forum" <gradsusr at gradsusr.org>
Sent: Saturday, January 18, 2014 3:41:20 PM
Subject: Re: [gradsusr] Serious Lterp Issue With GFS Data & Climatology Data
Hi Eric,
Thank you very much for responding! I use xcbar to plot my colorbars.
I've attached a sample of the anomaly graphic to this email, as well as the latest working script.
Onward and Upward,
Aaron D. Perry
Boston, MA
Lyndon State College '16
Twitter: @AaronPerryLSC
Mobile: 617-780-4312
From: gradsusr-bounces at gradsusr.org [gradsusr-bounces at gradsusr.org] on behalf of Eric Altshuler [ela at cola.iges.org]
Sent: Friday, January 17, 2014 11:56 PM
To: GrADS Users Forum
Subject: Re: [gradsusr] Serious Lterp Issue With GFS Data & Climatology Data
Hi Aaron,
You need to include a color bar on your plot, showing numerical values for each color. Without it, there's no way to know quantitatively what the anomalies are. This grads script will make a color bar:
ftp://cola.gmu.edu/grads/scripts/cbarn.gs
Run the cbarn.gs script immediately after displaying the anomaly variable.
Best regards,
Eric L. Altshuler
Research Scientist
Center for Ocean-Land-Atmosphere Studies
253 Research Hall, Mail Stop 6C5
George Mason University
4400 University Drive
Fairfax, VA 22030 USA
E-mail: ela at cola.iges.org
Phone: (703) 993-5725
Fax: (703) 993-5770
----- Original Message -----
From: "Aaron @ LSC Perry" <Aaron.Perry at lsc.vsc.edu>
To: "GrADS Users Forum" <gradsusr at gradsusr.org>
Sent: Friday, January 17, 2014 3:15:00 PM
Subject: Re: [gradsusr] Serious Lterp Issue With GFS Data & Climatology Data
Hi Jim,
I was able to get the script to work with that you suggested! Thank you! This method seems to be the only method that really works. I've been experimenting with another method for getting the 850mb temp anoms but, I end up getting crazy library errors and then it crashes GrADS.
I attached an image of what I was able to generate for 850mb anoms. Does it look reasonable?
Onward and Upward,
Aaron D. Perry
Boston, MA
Lyndon State College '16
Twitter: @AaronPerryLSC
Mobile: 617-780-4312
________________________________________
From: gradsusr-bounces at gradsusr.org [gradsusr-bounces at gradsusr.org] on behalf of James T. Potemra [jimp at hawaii.edu]
Sent: Friday, January 17, 2014 1:17 AM
To: GrADS Users Forum
Subject: Re: [gradsusr] Serious Lterp Issue With GFS Data & Climatology Data
Hi Aaron,
I'm a little confused as to the problem. What is error you are
getting? When you load two different files you are
potentially loading two different grids, including x/y/z/t. In these
cases it's much easier to define lat/lon/z/t
for each first. In your example below, you open one file, then the
next, then define lon/lat. Try this instead:
1. open first file
2. define lat/lon/z/t range
3. define new variable (in this case terp1)
4. open second file
5. set dfile 2
6. define lat/lon/z/t range
7. define new variable (in this case terp2)
This will at least help narrow down whether you have mismatched grids
and if so in what dimension. In your
example file below the vertical dimension will default to the grid in
the first file. I assume you want to interpolate
lat/lon from one file to the lat/lon of the other? I don't think lterp
works in the vertical.
Jim
On 1/16/14 1:10 PM, Perry, Aaron @ LSC wrote:
> Good Evening Andrew,
>
> I tried to incorporate the modify command into the script according to the modify example in the GrADS documentation but, no luck.
>
>
> Onward and Upward,
>
> Aaron D. Perry
> Boston, MA
> Lyndon State College '16
> Twitter: @AaronPerryLSC
> Mobile: 617-780-4312
>
> ________________________________________
> From: gradsusr-bounces at gradsusr.org [gradsusr-bounces at gradsusr.org] on behalf of Andrew Friedman [andfried at berkeley.edu]
> Sent: Thursday, January 16, 2014 5:55 PM
> To: GrADS Users Forum
> Subject: Re: [gradsusr] Serious Lterp Issue With GFS Data & Climatology Data
>
> Hi Aaron,
> Have you tried the ‘modify’ command for making the climatology apply to the whole record?
> Andrew
>
> On Jan 16, 2014, at 7:57 PM, Perry, Aaron @ LSC <Aaron.Perry at lsc.vsc.edu> wrote:
>
>> Hi Everyone,
>>
>> I tried setting the time dimensions to the same value (t=1) and it looks like the climo data is showing but, now I need to subtract the operational model data from the climo data to get the anomalies.
>>
>> Here's the revised script:
>>
>> 'open 'ctl1''
>> 'open 'ctl2''
>>
>> 'set mproj nps'
>> 'set lat 'latmin' 'latmax''
>> 'set lon 'lonmin' 'lonmax''
>> 'set mpvals -130 -64 20 70'
>> 'set display color white'
>> 'clear'
>> 'set map 1 1 10'
>> 'set mpdset hires'
>> 'set grid off'
>>
>> 'set grads off'
>> 'set timelab off'
>> 'set gxout shade2b'
>>
>> 'define terp2 = TMPprs.2(lev=850)'
>> 'define terp1 = TMP850mb.1'
>>
>> 'define newvar = lterp(terp1(t=1),terp2(t=1))'
>>
>> 'd newvar'
>>
>> Any ideas for getting this to work? It seems simple enough but...
>>
>>
>>
>> Onward and Upward,
>>
>> Aaron D. Perry
>> Boston, MA
>> Lyndon State College '16
>> Twitter: @AaronPerryLSC
>> Mobile: 617-780-4312
>> From: gradsusr-bounces at gradsusr.org [gradsusr-bounces at gradsusr.org] on behalf of Jeff Duda [jeffduda319 at gmail.com]
>> Sent: Thursday, January 16, 2014 1:03 PM
>> To: GrADS Users Forum
>> Subject: Re: [gradsusr] Serious Lterp Issue With GFS Data & Climatology Data
>>
>> Remove the double quotes in your time strings and see if that makes any difference.
>>
>>
>> On Thu, Jan 16, 2014 at 7:00 AM, Andrew Friedman <andfried at berkeley.edu> wrote:
>> Hi Aaron,
>>
>> I think your time indices need to be the same for lterp to work. Check out examples 4 and 5 in the documentation entry for lterp, which show how to manually override the time values. Hope this helps.
>>
>> Andrew
>>
>> On Jan 16, 2014, at 3:26 AM, Perry, Aaron @ LSC <Aaron.Perry at lsc.vsc.edu> wrote:
>>
>>> Good Evening Everyone,
>>>
>>> Currently, I'm having an issue with lterping two variables, one being 850mb temp with a recent GFS .ctl file and a climatological 850mb temp .ctl. The recent GFS .ctl is fine and the climate .ctl is coarse. I have been trying to read up on lterp as much as possible but, I can't seem to get this work and I've reached the end of possible resources it seems like...
>>>
>>> The script in question is below:
>>>
>>> ctl1 = '~/grads/data/cfsrclim/t850.cfsr.mean.clim.daily.1982.2010.ctl'
>>> ctl2 = '~/grads/data/gfs.t12z.pgrbf33.ctl'
>>>
>>> 'open 'ctl1''
>>> 'set x 1 360'
>>> 'open 'ctl2''
>>>
>>> 'set dfile 1'
>>> 'define t850clim = (TMP850mb-273.15)*(9/5)+32)'
>>>
>>> 'set dfile 2'
>>> 'define t850curr = (tmpprs(lev=850)-273.15)*(9/5)+32)'
>>>
>>> 'define t850a = (t850clim(t="00Z01jan1984"))'
>>>
>>> 'define t850b = (t850curr(t="18Z15jan2014"))'
>>>
>>> 'define final = lterp(t850b,t850a)'
>>>
>>> 'define hi = t850a-final'
>>>
>>> 'd hi'
>>>
>>>
>>> Onward and Upward,
>>>
>>> Aaron D. Perry
>>> Boston, MA
>>> Lyndon State College '16
>>> Twitter: @AaronPerryLSC
>>> Mobile: 617-780-4312
>>> <climtest.gs>_______________________________________________
>>> gradsusr mailing list
>>> gradsusr at gradsusr.org
>>> http://gradsusr.org/mailman/listinfo/gradsusr
>>
>> _______________________________________________
>> gradsusr mailing list
>> gradsusr at gradsusr.org
>> http://gradsusr.org/mailman/listinfo/gradsusr
>>
>>
>>
>> --
>> Jeff Duda
>> Graduate research assistant
>> University of Oklahoma School of Meteorology
>> Center for Analysis and Prediction of Storms
>> _______________________________________________
>> gradsusr mailing list
>> gradsusr at gradsusr.org
>> http://gradsusr.org/mailman/listinfo/gradsusr
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
_______________________________________________
gradsusr mailing list
gradsusr at gradsusr.org
http://gradsusr.org/mailman/listinfo/gradsusr
_______________________________________________
gradsusr mailing list
gradsusr at gradsusr.org
http://gradsusr.org/mailman/listinfo/gradsusr
_______________________________________________
gradsusr mailing list
gradsusr at gradsusr.org
http://gradsusr.org/mailman/listinfo/gradsusr
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20140121/21b90c0e/attachment.html
More information about the gradsusr
mailing list