[gradsusr] Help in defining a variable.
Muhammad Yunus Ahmad Mazuki
ukm.yunus at gmail.com
Fri Nov 9 05:27:31 EST 2012
Hello,
I used a script to pull out the altitude/pressure level of a variable. It
was the location of the altitude of a maximum variable value over a volume
box. The main part of the scrip is as below. I also did the same for the
maximum value of the variable, longitude and latitude as well. So the
altitude became a variable data of pressure level against time, the same as
others.
ti=1
while (ti <=360)
'd maxloc(max(max(var1,lon=40,lon=270),lat=-40,lat=-20),lev=100, lev=300)'
maxloc=sublin(result,114)
zloc=subwrd(maxloc,4)
'set z 'zloc
v4.n=subwrd(result,4)
'reset'
n=n+1
ti=ti+1
endwhile
The question is how do I define the variable of altitude in a control file?
For others, I use:
tv 0 99 1 variable maximum value (K)
lonv 0 99 1 longitude(degree)
latv 0 99 1 latitude(degree)
I tried "altv 0 99 1 altitude(hPa)", but I'm not sure its correct, because
I can't pull out the altitude data into a text file using the script below.
The script works just fine for other variables (the variable, latitude and
longitude), perhaps because the are linear. the altitude is no however.
tt=1
while(tt<=360)
'set t 'tt
'd altv'
res1=subwrd(result,4)
rec=write('ua_ERA-altv-mnthly.txt',res1,append)
tt=tt+1
endwhile
Originally the altitude or the z level is defined as ZDEF 37 LEVELS 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. I hope this
information helps. So, how do I define a nonlinear variable in the control
file?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20121109/29264060/attachment-0003.html
More information about the gradsusr
mailing list