PureBytes Links
Trading Reference Links
|
MetaStock's standard Simple MA, 201 periods, -100 horizontal shift
(half of the SMA's periodicity), matches your center plot exactly. I
see nothing wrong with your code.
jose '-)
http://www.metastocktools.com
--- In equismetastock@xxxxxxxxxxxxxxx, "robcpettit" <robcpettit@xxxx>
wrote:
> Could somebody look at this formula for indicator and advis me why
> its out of lie vertically.
> Average:=Input("TimePeriods",0,2000,201);
>
> totalAveperiods:=LastValue(Cum(Mov(C,Average,S)>-1000));
> shift:=Average/2;
>
> mildev:=(
> Sqrt(((Sum(Power(Ref(C,-shift)-Mov(C,Average,S),2),totalAveperiods))
-(Power(Sum(Ref(C,-shift)-Mov(C,Average,S),
> totalAveperiods),2)/ totalAveperiods))/(totalAveperiods-1)));
>
>
> mildev;
>
> Upper := (Mov(C,Average,S) + LastValue(2*LastValue(mildev)));
> Ref(Upper,shift);
>
> Ave:=Mov(C,Average,S);
> Ref(Ave,shift);
>
> Lower := (Mov(C,Average,S) - (2*LastValue(mildev)));
> Ref(lower,shift);
>
>
> I can move it back in time ok, in other words centre it, I cant seem
> to get it to match a centered ma built in to metastock. What Ive
> been doing to check is plot a 201 day centred ma in metastock and
> then try to mine to it, without success.
>
> Regards Robert
------------------------ Yahoo! Groups Sponsor --------------------~-->
Has someone you know been affected by illness or disease?
Network for Good is THE place to support health awareness efforts!
http://us.click.yahoo.com/Rcy2bD/UOnJAA/cosFAA/BefplB/TM
--------------------------------------------------------------------~->
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/equismetastock/
<*> To unsubscribe from this group, send an email to:
equismetastock-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|