<div dir="ltr"><div><div><div><div><div><div><div>Hi Andrew,<br><br></div>Exactly! <br><br></div>You have been of great help, Andrew. <br></div></div></div>Thanks and have a good day!<br></div><div><br></div>Regards,<br></div>Malcolm<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Dec 25, 2015 at 6:54 AM, Andrew Friedman <span dir="ltr"><<a href="mailto:andfried@gmail.com" target="_blank">andfried@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Malcolm,<br>
<br>
I believe that what you are doing by plotting trendlast-trendl is comparing the fitted trend line at the last time step minus that of the first time step.<br>
I think that (trendlast-trendl)/ # of time steps should equal the slope. Is that what you find?<br>
<br>
Best, Andrew<br>
<div class="HOEnZb"><div class="h5"><br>
> On Dec 23, 2015, at 5:11 AM, Malcolm Tang <<a href="mailto:malct32@gmail.com">malct32@gmail.com</a>> wrote:<br>
><br>
> Hi Andrew,<br>
><br>
> Thanks for your guidance, it worked wonderfully.<br>
><br>
> Just a quick question, though.<br>
><br>
> 'sdfopen <a href="http://precipitation.nc" rel="noreferrer" target="_blank">precipitation.nc</a>'<br>
> 'set lon 0 360'<br>
> 'set lat -90 -75'<br>
> 'set mproj sps'<br>
> 'set t 1 last'<br>
><br>
> 'd precipitation'<br>
> 'ltrend precipitation precl slope error'<br>
> 'c'<br>
><br>
> 'set t 1'<br>
> 'd precl'<br>
> 'define trend1=precl'<br>
><br>
> 'c'<br>
> 'set t last'<br>
> 'd precl'<br>
> 'define trendlast=precl'<br>
> 'c'<br>
><br>
> 'd trendlast-trendl'<br>
><br>
> *a spatial map comes out*<br>
><br>
> Is this the correct way to display the fluctuation of precipitation trend?<br>
><br>
> Regards,<br>
> Malcolm<br>
><br>
> On Fri, Dec 18, 2015 at 4:59 AM, Andrew Friedman <<a href="mailto:andfried@gmail.com">andfried@gmail.com</a>> wrote:<br>
> Hi Malcolm,<br>
><br>
> If you are looking for the slope (the rate of change per time step) you need to add another term when you call trend<br>
><br>
> For example:<br>
> 'ltrend prec precl precslope'<br>
><br>
> >From the <a href="http://ltrend.gs" rel="noreferrer" target="_blank">ltrend.gs</a>”<br>
><br>
> ga-> ltrend<br>
> Calculate linear trend over time (based on least-squares fitting).<br>
><br>
> USAGE: ltrend <input> [<output> [<slope> [<rmse>]]]<br>
> <input>: input field. Can be any GrADS expression.<br>
> <output>: output field, i.e., fitted trend line. Default=<input>.<br>
> <slope>: slope of fitted trend line, i.e., change of <input> per time step.<br>
> <rmse>: root mean square error.<br>
><br>
> Andrew<br>
><br>
> > On Dec 17, 2015, at 1:28 PM, Malcolm Tang <<a href="mailto:malct32@gmail.com">malct32@gmail.com</a>> wrote:<br>
> ><br>
> > Hi Andrew,<br>
> > Yes I've set it as<br>
> ><br>
> > "set t 1 last"<br>
> ><br>
> > For your info, I tried this and a spatial map came out:<br>
> ><br>
> > 'set lon 0 360'<br>
> > 'set lat -90 -75'<br>
> > 'set mproj sps'<br>
> > 'set t 1 last'<br>
> ><br>
> > 'd prec'<br>
> ><br>
> > 'ltrend prec precl'<br>
> ><br>
> > 'd precl'<br>
> ><br>
> > I'm not sure if it's the spatial trend map that I'm looking for though....<br>
> ><br>
> > But since the time is set from 1 to last, I can observe that the map actually changes from 1 to the last time step.<br>
> ><br>
> > Any idea or suggestion?<br>
> ><br>
> > Thanks.<br>
> > Malcolm<br>
> ><br>
> ><br>
> > On Thu, Dec 17, 2015 at 5:32 PM, Andrew Friedman <<a href="mailto:andfried@gmail.com">andfried@gmail.com</a>> wrote:<br>
> > Hi Malcolm,<br>
> ><br>
> > In your text earlier, it looks like your time is set to 1. Can you try setting time to varying?<br>
> ><br>
> > Andrew<br>
> ><br>
> > > On Dec 17, 2015, at 3:38 AM, Malcolm Tang <<a href="mailto:malct32@gmail.com">malct32@gmail.com</a>> wrote:<br>
> > ><br>
> > > Hi Andrew,<br>
> > ><br>
> > > I removed the bracket and ....... nothing came out?<br>
> > ><br>
> > > I typed:<br>
> > ><br>
> > > "ltrend prec fitted trend line" nothing came out.<br>
> > ><br>
> > > "ltrend prec fitted trend line 0.2 0.025" nothing came out.<br>
> > ><br>
> > > Should I be expecting a result or something? Because I'm expecting a spatial map to come up.<br>
> > ><br>
> > > Thanks!<br>
> > > Malcolm<br>
> > ><br>
> > > On Wed, Dec 16, 2015 at 4:05 PM, Andrew Friedman <<a href="mailto:andfried@gmail.com">andfried@gmail.com</a>> wrote:<br>
> > > HI Malcolm,<br>
> > ><br>
> > > You shouldn’t type the brackets - they’re placeholders to indicate optional values.<br>
> > ><br>
> > > Andrew<br>
> > ><br>
> > > > On Dec 16, 2015, at 4:55 AM, Malcolm Tang <<a href="mailto:malct32@gmail.com">malct32@gmail.com</a>> wrote:<br>
> > > ><br>
> > > > Hi all,<br>
> > > ><br>
> > > > I want to plot the trend map of precipitation in antarctica (75s-90s) from 1999-2015.<br>
> > > ><br>
> > > > I have done some searching and saw someone suggested using BinGuan's script <a href="http://ltrend.gs" rel="noreferrer" target="_blank">ltrend.gs</a><br>
> > > > I have copied the script and the dependencies qdims.gsf.<br>
> > > ><br>
> > > > So these are what I type in grads:<br>
> > > ><br>
> > > > 'set lon 0 360'<br>
> > > > 'set lat -90 -75'<br>
> > > > 'set mproj sps'<br>
> > > > 'set t 1'<br>
> > > ><br>
> > > > 'd prec'<br>
> > > > 'ltrend prec [fitted trend line [0.2[0.025]]]'<br>
> > > ><br>
> > > > and there will be error coming out: DEFINE error: Name too long; missing '='<br>
> > > ><br>
> > > > Anyone who has experience with <a href="http://ltrend.gs" rel="noreferrer" target="_blank">ltrend.gs</a> PLEASEEEEEEE help!!!<br>
> > > ><br>
> > > > Thanks<br>
> > > > Malcolm<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" rel="noreferrer" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
> > ><br>
> > ><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" rel="noreferrer" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
> > ><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" rel="noreferrer" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
> ><br>
> ><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" rel="noreferrer" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
> ><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" rel="noreferrer" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
><br>
><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" rel="noreferrer" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
><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" rel="noreferrer" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
<br>
<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" rel="noreferrer" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
</div></div></blockquote></div><br></div>