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

Re: Easy language to MS translation HELP



PureBytes Links

Trading Reference Links

GlacierMichel,

Did someone post the solution to your question ????

If so, I missed it and would like to see in
Metastock functions what this Easy Language
code looks like.  It seems to be the "Adaptive
Bollinger Band" idicator.

Thanks, ............. John

----- Original Message -----
From: Michel Amelinckx
To: metastock@xxxxxxxxxxxxx
Sent: Friday, November 24, 2000 5:37 PM
Subject: RE: Easy language to MS translation HELP


Thanks for the help!!!
-----Original Message-----
From: owner-metastock@xxxxxxxxxxxxx [mailto:owner-metastock@xxxxxxxxxxxxx]On
Behalf Of Michel Amelinckx
Sent: donderdag 23 november 2000 0:50
To: Metastock User List (E-mail)
Subject: Easy language to MS translation HELP


Hello,
Is there someone who is willing to help me to translate this system coded in
easy language to MS.  Many THANKS in advance


}
inputs:BBLength(38),BBStdDev(3),
BBHPrice(ADAPTIVE(H,10)),BBLPrice(ADAPTIVE(L,10));

vars:BBH(0),BBL(0);

BBH=BollingerBand(BBHPrice,BBLength,BBStdDev);
BBL=BollingerBand(BBLPrice,BBLength,-BBStdDev);

if c >bbh then buy;
if c<bbl then sell;

{
P.S. The adaptive function part is Perry Kaufmans:
}
inputs:price(numericseries),period(numericsimple);

vars: noise(0),signal(0),dif(0),efratio(0),
       smooth(1),fastend(.666),slowend(.0645),am(0);

{CALCULATE EFFICIENCY RATIO}
dif=@xxxxxxxx(price - price[1]);
if(currentbar <= period) then am =price;
if(currentbar > period)then begin
        signal = @AbsValue(price - price[period]);
        noise = @summation(dif,period);
        efratio = signal/noise;
        smooth = @Power(efratio*(fastend - slowend) + slowend,2);

{ADAPTIVE MOVING AVERAGE}
       am = am[1] + smooth*(price - am[1]);
     Adaptive=am;
        end;
Greeting

Mickey