<div dir="ltr"><div><div>Hi Atiqah,<br><br></div>I think one problem is that zICnew varies in space and time, but the first argument of tcorr can only vary in time. <br><br></div>Andrew<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jun 2, 2015 at 8:52 AM, syairah atiqah atiq <span dir="ltr"><<a href="mailto:syairahatiqah@yahoo.com" target="_blank">syairahatiqah@yahoo.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div style="color:#000;background-color:#fff;font-family:verdana,helvetica,sans-serif;font-size:13px"><div>Can anyone help me with the below scripts. I get an error when I run it.</div><div><br></div><div>'reinit'</div><div>*</div><div>* sea ice cover;</div><div>* -------------</div><div>*</div><div> 'sdfopen D:\atiqah\GrADs\Real\Data\montly\SeaIceCover_19792014.nc'</div><div>*</div><div>* </div><div> 'set dfile 1'</div><div> 'set lon 0 360'</div><div> 'set lat -90 -55'</div><div>*</div><div> 'icMJJAS=ave(ci*100,t=5,t=417,12)'</div><div>*</div><div> 'clim5=ave(ci*100,t=5,t=413,12)'</div><div> 'clim6=ave(ci*100,t=6,t=414,12)'</div><div> 'clim7=ave(ci*100,t=7,t=415,12)'</div><div> 'clim8=ave(ci*100,t=8,t=416,12)'</div><div> 'clim9=ave(ci*100,t=9,t=417,12)' </div><div>*</div><div> 'climavg=clim5+clim6+clim7+clim8+clim9/5'</div><div>*</div><div> 'anomIC=icMJJAS-climavg'</div><div>*</div><div> 'avg2=(ave(pow(clim5-ci,2),t=5,t=413,12)+ave(pow(clim6-ci,2),t=6,t=414,12)+ave(pow(clim7-ci,2),t=7,t=415,12)+ave(pow(clim8-ci,2),t=8,t=416,12)+ave(pow(clim9-ci,2),t=9,t=417,12))/5'</div><div>*</div><div> 'stDv=sqrt(avg2)'</div><div>*</div><div> 'zIC=anomIC/stDv'</div><div>*</div><div>* MSLP MH;</div><div>* ========</div><div>*</div><div> 'sdfopen D:\atiqah\GrADs\Real\Data\montly\MSLP_ST_TP_1979_2014.nc'</div><div>*</div><div> 'set dfile 2'</div><div> 'set lon 40E 90E'</div><div> 'set lat 25S 35S'</div><div>*</div><div> 'mslMJJAS=ave(msl,t=5,t=417,12)'</div><div>*</div><div> 'clim5=ave(msl,t=5,t=413,12)'</div><div> 'clim6=ave(msl,t=6,t=414,12)'</div><div> 'clim7=ave(msl,t=7,t=415,12)'</div><div> 'clim8=ave(msl,t=8,t=416,12)'</div><div> 'clim9=ave(msl,t=9,t=417,12)' </div><div>*</div><div> 'climavg=clim5+clim6+clim7+clim8+clim9/5'</div><div>*</div><div> 'anomMH=mslMJJAS-climavg'</div><div>*</div><div>*</div><div> 'avg2=(ave(pow(clim5-msl,2),t=5,t=413,12)+ave(pow(clim6-msl,2),t=6,t=414,12)+ave(pow(clim7-msl,2),t=7,t=415,12)+ave(pow(clim8-msl,2),t=8,t=416,12)+ave(pow(clim9-msl,2),t=9,t=417,12))/5'</div><div>*</div><div> 'stDv=sqrt(avg2)'</div><div>*</div><div>*</div><div> 'zMH=anomMH/stDv'</div><div>*</div><div>* set same grid for both file;</div><div>* ==========================</div><div>*</div><div> 'zICnew=re2(zIC,0.25,0.25,ba)'</div><div> 'zMHnew=re2(zMH,0.25,0.25,ba)'</div><div>*</div><div>* Correlation;</div><div>* ===========</div><div>*</div><div> 'set t 1 12'</div><div> 'set lon 80 200'</div><div> 'set lat -90 28'</div><div> 'define corr=tcorr(zICnew,zMHnew,t=5,t=417)'</div><div dir="ltr"> 'd corr'</div><div dir="ltr"><br></div><div dir="ltr">Error from TCORR: 1st arg must be 0-D</div><div dir="ltr">Error from TCORR: Error getting grids</div><div dir="ltr">Operation Error: Error from tcorr function</div><div dir="ltr"> Error ocurred at column 1</div><div dir="ltr">DEFINE error: Invalid expression.</div><div dir="ltr"><br></div><div dir="ltr">Thank in advance</div><span class="HOEnZb"><font color="#888888"><div dir="ltr"><br></div><div dir="ltr">Atiqah</div><div><br></div></font></span></div></div><br>_______________________________________________<br>
gradsusr mailing list<br>
<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
<a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
<br></blockquote></div><br></div>