<div dir="ltr">you check once as follows<div><br></div><div style>set lon 61.25 143.75</div><div style>set lat 8.75 56.25</div><div style>d maskout(pdsi,1)</div><div style><br></div><div style>if it visualizes only your area, your code should be right . Otherwise, try as I suggested</div>
<div style><br></div><div style>Best regards,</div><div style><br></div><div style>Kishore</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Sun, Apr 14, 2013 at 11:55 AM, Kishore Ragi <span dir="ltr"><<a href="mailto:kishoreragi@gmail.com" target="_blank">kishoreragi@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">hi,<div><br></div><div>You have opened maskout_china.ctl as second file so the command should be as follow</div>
<div><br></div><div><br></div><div><strong style="font-family:arial,sans-serif;font-size:12.727272033691406px"><font color="#ff0000">'define mpdsi=aave(maskout(pdsi,mask.2),lon=x1,lon=x2,lat=y1,lat=y2)' </font></strong><br>
</div><div><br></div><div>I don't know about your tloop but, it give area average (country average) of your interest leaving rest of the area.<br></div><div><br></div><div>Hope it solves your purpose....</div>
<div><br></div><div>Best regards,</div><div><br></div><div>Kishore</div></div><div class="gmail_extra"><br><br><div class="gmail_quote"><div><div class="h5">On Sun, Apr 14, 2013 at 11:33 AM, <span dir="ltr"><<a href="mailto:fairyes@zju.edu.cn" target="_blank">fairyes@zju.edu.cn</a>></span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><p>Dear Kishore,</p>
<p>Thank you for your remind. I'm sorry for my unclearly expression. </p>
<p>I want to get the timeseries of average pdsi value about china, next is the gs file I once used which was not precisely about china:<br>'sdfopen d:/grads/mada/data.cdf'<br>'set lon 73.66'<br>'set lat 4'<br>
'set lev 0 0'<br>'set e 1 1'<br>'set t 114 121'<br>'define mpdsi=tloop(aave(pdsi,lon=73.66,lon=135.08,lat=4,lat=53.52))'<br>'set xlopts 1 5 0.25'<br>'set ylopts 1 5 0.15'<br>
'set gxout line'<br>'set cthick 7'<br>'set grads off'<br>'d mpdsi'<br>'draw title MADA,IVI2 event_1416'<br>'printim d:/grads/mada/event_1416.png white x1600 y1200'<br>;<br>
</p>
<p>then after saw the method, I tried it to make my timeseries precisely about china, as the pdsi data are in a <span lang="EN-US"><font color="#ff0000" face="Calibri">2.5</font></span><span style="FONT-FAMILY:宋体"><font color="#ff0000">°regular grid</font>, I set the xsize and ysize in meteoinfo to <font color="#ff0000">both 2.5</font>, and then get the maskout_china dat file and ctl file from meteoinfo, after that, as the ctl file of pdsi data are built-in,and after I use sdopen comman to open the data.cdf, it shows the 'time values set: 1300:6:23:18 ', and I have known its time period are from 1300 to 2005, so I changed the next part in maskout_china ctl file:<font color="#ff0000"> TDEF 706 LINEAR 18:00Z23JUN1300 1yr</font>. </span></p>
<p><span style="FONT-FAMILY:宋体">Then I change my gs file as below:</span></p>
<p><span style="FONT-FAMILY:宋体"></span>'sdfopen d:/grads/mada/data.cdf'<br>'open d:/grads/mada/maskout_china.ctl'<br>'set lon 73.66'<br>'set lat 4'<br>'set lev 0 0'<br>'set e 1 1'<br>
'set t 114 121'<br><strong><font color="#ff0000">'define mpdsi=tloop(aave(pdsi,maskout(pdsi,mask)))'</font></strong><br>'set xlopts 1 5 0.25'<br>'set ylopts 1 5 0.15'<br>'set gxout line'<br>
'set cthick 7'<br>'set grads off'<br>'d mpdsi'<br>'draw title MADA,IVI2 event_1416'<br>'printim d:/grads/mada/event_1416_precise.png white x1600 y1200'<br>;</p>
<p>when I run the above gs file, opengrads showed: error from aave: too many or two few args 5 arguments expected operation error: error from aave function operation error: error from tloop function error occured at column 1 define error: invalid expression syntax error: invalid operand 'mpdsi' not a variable or function name error occured at column 1 display error: invalid expression expression = mpdsi</p>
<p>Maybe I just didn't know how to use the maskout_china dat and ctl file correctly in my gs file, or the modification of maskout_china ctl file I made have some errors? I don't know why it shows so many errors in the next while it can be done in the above one. Any guidance or tip? Thank you very much!</p>
<p>Looking forward to your reply! Best regards!</p>
<p>Zhihong</p>
<p> </p>
<p> </p>
<p><br><span>--<br></span></p><div><div>
<p> Zhihong Zhuo,Postgraduate Student</p>
<p><font face="Times New Roman"> College of Environmental and Resource Sciences, Zhejiang University</font></p>
<p><font face="Times New Roman">Address: 866 Yuhangtan Road, Hangzhou, China</font></p>
<p><font face="Times New Roman">Email: <a href="mailto:fairyes@zju.edu.cn" target="_blank">fairyes@zju.edu.cn</a></font></p>
<p><font face="Times New Roman"></font> </p></div></div><br></div></div><div class="im">_______________________________________________<br>
gradsusr mailing list<br>
<a href="mailto:gradsusr@gradsusr.org" target="_blank">gradsusr@gradsusr.org</a><br>
<a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
<br></div></blockquote></div><br></div>
</blockquote></div><br></div>