[gradsusr] please give me solution for my querries

subrahmanyam mantravadi dr.mvsubrahmanyam at gmail.com
Tue Apr 10 16:49:19 EDT 2012


Dear All,

I like to plot the olr and win vectors in the same plot. i am trying to
plot, but only olr has been plotted. i want to show both in the same plot.
please give me solution for them.

script:1

'reinit'
'sdfopen h:\ncep\ncep\olr1980.nc'
'sdfopen h:\ncep\ncep-winds\10m\uwnd.10m.gauss.2010.nc'
'sdfopen h:\ncep\ncep-winds\10m\vwnd.10m.gauss.2010.nc'
'enable print h:\ncep\ncep\olrwin-80.gmf'
'set lat -35 25'
'set lon 265 345'
tt=1
while(tt<=12)
'set t 'tt
'define ol=ulwrf.1'
'set gxout contour'
*'set gxout shaded'
'set grads off'
'set grid on'
'set ccolor -1'
'set clevs 180 190 200 210 220 230 240 250 260 270 280 290 300'
*'set ccols 180 190 200 210 220 230 240 250 260 270 280 290 300'
'd ulwrf.1'
*'cbarn'
'q time'
a=sublin(result,1)
b=subwrd(a,3)
'draw title OLR  'b

'define u1=uwnd.2'
'define v1=vwnd.3'
'set gxout vector'
'set grads off'
'set grid on'
'd u1;v1'
'print'
'c'
tt=tt+1
endwhile
'disable print'
'reinit'

result: getting only contours, no vectors.


another, i want to calculate the anomalies. i have both year file (with
monthly mean) at the same long term monthly mean, i would like to calculate
the anomaly and plot the same. monthly mean data was taken but the long
term mean file showing error, file number out of range.

Script: 2

'reinit'
'sdfopen h:\ncep\ncep-olr-mon\1975olr.nc'
'sdfopen h:\ncep\ncep-olr-mon\olr.mon.ltm.nc'
'enable print h:\ncep\ncep-olr-mon\1975olranom.gmf'
*'set lat -35 25'
*'set lon 165 345'
tt=1
while(tt<=12)
'set t 'tt
'define ol=olr.1'
'define lt=olr.2'
'define anom=ol-lt'
'set lat -35 25'
'set lon 165 345'
'set gxout contour'
*'set gxout shaded'
'set grads off'
'set grid on'
'set ccolor -1'
*'set clevs 180 190 200 210 220 230 240 250 260 270 280'
'd anom'
*'cbarn'
'q time'
a=sublin(result,1)
b=subwrd(a,3)
'draw title OLR  'b
'print'
'c'
tt=tt+1
endwhile
'disable print'
'reinit'

result: error.

please give me solution for those two. i am using windows based grads
(Grads 2.0.1.oga.1 in windows vista)


thanks in advance.
-- 
M.V.Subrahmanyam
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20120410/e5761e4e/attachment-0003.html 


More information about the gradsusr mailing list