PureBytes Links
Trading Reference Links
|
Ray,
This should work (using the Close array):
s5 = IIf(Cum(1) > BarCount-14, MA(Close, 5), Null);
Plot(s5, etc...);
Actually, I just noticed there's a new function called BarIndex()
which will do the same job:
s5 = IIf(BarIndex() >= BarCount-14, MA(Close, 5), Null);
GP
--- In amibroker@xxxxxxxxxxxxxxx, "ax_ray2222" <ax_ray2222@xxx> wrote:
>
> Hello, I try to plot a SMA(5) only for the last 14 days on the chart,
> but I can't figure out how to write the formula to do this. Any help is
> appreciated, Thank you, Ray
>
Please note that this group is for discussion between users only.
To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com
For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/
For other support material please check also:
http://www.amibroker.com/support.html
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/amibroker/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:amibroker-digest@xxxxxxxxxxxxxxx
mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx
<*> To unsubscribe from this group, send an email to:
amibroker-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|