[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: center of gravity oscillator



PureBytes Links

Trading Reference Links

Yupips' code for Metastock (Typ can be used in place of MP, which is
midpoint):

{J.Ehlers Center of Gravity: TASC 5/2002}
Num:= MP();
Num:= Num + (2 * Ref(MP(),-1));
Num:= Num + (3 * Ref(MP(),-2));
Num:= Num + (4 * Ref(MP(),-3));
Num:= Num + (5 * Ref(MP(),-4));
Num:= Num + (6 * Ref(MP(),-5));
Num:= Num + (7 * Ref(MP(),-6));
Num:= Num + (8 * Ref(MP(),-7));
Num:= Num + (9 * Ref(MP(),-8));
Num:= Num + (10 * Ref(MP(),-9));

Denom:= MP();
Denom:= Denom + Ref(MP(),-1);
Denom:= Denom + Ref(MP(),-2);
Denom:= Denom + Ref(MP(),-3);
Denom:= Denom + Ref(MP(),-4);
Denom:= Denom + Ref(MP(),-5);
Denom:= Denom + Ref(MP(),-6);
Denom:= Denom + Ref(MP(),-7);
Denom:= Denom + Ref(MP(),-8);
Denom:= Denom + Ref(MP(),-8);

{CG:= (Div(Num,Denom)) * -1;}
CG:= (Num / Denom) * -1;
CG1:= Ref(CG,-1);
CG;
CG1




----- Original Message -----
From: "HARISH CHHEDA" <chhedaad1@xxxxxxxxxxxxx>
To: <metastock@xxxxxxxxxxxxxxxxxx>
Sent: Thursday, May 02, 2002 10:33 PM
Subject: Re: center of gravity oscillator


> Please send me a copy
> Thanks
> Harish Chheda
>
>
>