Code: Select all
Variables: var0( 0 );
var0 = absvalue(OpenEntryMinProfit(0)*0.02);
If Date[0] <> Date[1] or marketposition = 0 then var0 = 0;
If BarsSinceEntry = 19 then DrawDown = var0;
Code: Select all
If Date[0] <> Date[1] or marketposition = 0 then
Begin
SX1st = 0;
End;
If marketPosition = -1 and Time <= 1613 and PosTradeIsOpen(0,0) = True then
Begin
If PosTradeCount(0) = 3 and PosTradeIsOpen(0,2) = True then SX1st = AvgList(PosTradeEntryPrice(0,0), PosTradeEntryPrice(0,1), PosTradeEntryPrice(0,2)) else
If PosTradeCount(0) = 2 and PosTradeIsOpen(0,1) = True then SX1st = AvgList(PosTradeEntryPrice(0,0), PosTradeEntryPrice(0,1)) else
SX1st = PosTradeEntryPrice(0,0) + (DrawDown + 1);
End;
- 10/3/2016 15:50:00 Barstatus> 2.00 Study>$$$ Barssinceentry 52.00 SX Price>20009.00 DrawDown> 29.00
10/3/2016 15:50:00 Barstatus> 2.00 Study>%%% Barssinceentry 52.00 SX Price>20009.00 DrawDown> 29.00
10/3/2016 15:50:00 Barstatus> 2.00 Study>%%% Barssinceentry 52.00 SX Price>19980.00 DrawDown> 0.00
10/3/2016 15:50:00 Barstatus> 2.00 Study>%%% Barssinceentry 52.00 SX Price>20009.00 DrawDown> 29.00
10/3/2016 15:50:00 Barstatus> 2.00 Study>$$$ Barssinceentry 52.00 SX Price>20009.00 DrawDown> 29.00