<p class="MsoPlainText">Dear GrADS users,</p><p class="MsoPlainText"><br></p><p class="MsoPlainText">I
want to extract daily averages from a monthly file having 3 hourly out
put data. I am using the following script (in blue color). Script is
working fine but the result of daily averages obtained by this script
are different when I compare it by directly opening the 3 hourly output
file in GrADS and do manual daily average at particular lat and lon
information. The manual command is as follows.</p><br><p class="MsoPlainText">Any idea in this regard?<br></p><p class="MsoPlainText"><br></p><p class="MsoPlainText"><span style="color: rgb(0, 0, 255);">'set gxout fwrite'</span><br style="color: rgb(0, 0, 255);">
<span style="color: rgb(0, 0, 255);">
'disable fwrite'</span><br style="color: rgb(0, 0, 255);"><span style="color: rgb(0, 0, 255);">
'set fwrite SRF_avg_daily.grd'</span><br style="color: rgb(0, 0, 255);">
<span style="color: rgb(0, 0, 255);">
'open /RAID/RegCM_A2/ERA40_09/SRF.1961010100.ctl'</span><br style="color: rgb(0, 0, 255);"><span style="color: rgb(0, 0, 255);">
'set x 1 303'</span><br style="color: rgb(0, 0, 255);"><span style="color: rgb(0, 0, 255);">
'set y 1 226'</span><br style="color: rgb(0, 0, 255);">
<span style="color: rgb(0, 0, 255);" lang="ES">t=1<br>
tmax=248<br>
while(t<=tmax)<br>
'set t 't<br>
'define a=avg(t2min,t+0,t+7)'<br>
'd const(a,-9999.0,-u)'<br>
</span><span style="" lang="FR"><span style="color: rgb(0, 0, 255);">t=t+8</span><br style="color: rgb(0, 0, 255);"><span style="color: rgb(0, 0, 255);">
endwhile</span><br style="color: rgb(0, 0, 255);"><span style="color: rgb(0, 0, 255);">
'close 1'</span><br>
</span><br>
</p>
<br>Regards,<br><br><br>Mubashar<br><br clear="all"><br>-- <br>Muhammad Mubashar Ahmad Dogar<br>Scientific Officer (Climatology Section),<br>Global Change Impact Studies Centre (GCISC),<br>NCP complex, Quaid-e-Azam University Campus,<br>
Shahdra road, Islamabad, Pakistan.<br>Tel: +92519230226<br>Mob:+923315144169<br>email: <a href="mailto:mubashardogar@yahoo.com">mubashardogar@yahoo.com</a><br> <a href="mailto:mubashar.ahmad@gcisc.org.pk">mubashar.ahmad@gcisc.org.pk</a><br>