marketposition == 1 --> Long
marketposition == 0 --> No trades
marketposition == -1 --> Short
MaxtradeClose == First Item of array MaxTradeClose == Value of that array for current bar
So .. MaxTradeClose (in ELA) = MaxTradeClose[0] (in mq4).
MinTradeLow, MaxTradeClose ... and those variables are array used for temporal calculation based on calculation.
Quote:
|
Originally Posted by Alex.Piech.FinGeR
i not understand
this ELA code
-----Functions Used in the Code---------
{---Function MaxTradeClose---}
if marketposition <> 1 then MaxTradeClose=-999999;
if marketposition=1 and C>MaxtradeClose[1] then MaxtradeClose=C;
{---Function MinTradeClose---}
if marketposition <>-1 then MinTradeClose=999999;
if marketposition=-1 and C<MinTradeClose[1] then MinTradeClose=C;
{---Function MaxTradeHigh---}
if marketposition <> 1 then MaxTradeHigh=-999999;
if marketposition=1 and H>MaxtradeHigh[1] then MaxtradeHigh=H;
{---Function MinTradeLow---}
if marketposition <>-1 then MinTradeLow=999999;
if marketposition=-1 and L<MinTradeLow[1] then MinTradeLOw=L;
|