31.07.2021 Views

Ultimate Algorithmic Trading System

Using automated systems for trading in stock markets

Using automated systems for trading in stock markets

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

case(1):

begin

if h > state1Price then state1Price = h;

if low < state1Price * .98 then

begin

state = 2;

print(date," State 2 :",low);

value1 = text_new(date[1],time,

l-10,"S2");

text_setColor(value1,red);

end;

end;

end;

case(2):

begin

if isHiPivot and h[1] > state1Price then

begin

state = 3;

state3Price = h;

print(date," State 3 :", state3Price);

value1 = text_new(date[2],time,

h+20,"S3");;

text_setColor(value1,yellow);

end;

end;

case(3):

begin

if h > state3Price then state3Price = h;

if l < state3Price * .98 then

begin

buy this bar on close;

print(date," accept state : ",l);

value1 = text_new(date[1],time,

l-10,"S4");;

text_setColor(value1,GREEN);

state = 0;

end;

end;

225

AN INTRODUCTION TO EASYLANGUAGE

If barNumber - state1BarNumber > 30 then state = 0;

Sell next bar at lowest(l,60) stop;

www.rasabourse.com

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!