Previous Bar Trailing Stop - page 3

To add comments, please log in or register
myname
3232
myname  
mladen:
Maybe he is trading indices or something similar - who knows. Now it is possible to set the symmetricity (or assymetricity) so each trader can use it per will

Maybe he is trading that, but I fail to see the logic. It will lead to losses

Johnny
8
Johnny  

Sorry for the late reply, I was a bit busy.

It's working, thanks mladen.

Johnny
8
Johnny  

Is it possible to also add an option so the stop loss only jumps if the candle is in the right direction? In sell trades only move on downward candles and in buy trades only move on upward candles.

I tried adding this option myself but I failed miserably.

FxSteven
174
FxSteven  

Hello mladen i very like this ea , but i have problem .

My i know this ea can use it on renko too?

I have set the high low bar to 7 and trail only in profit to true .

Some time the stop loss will move when it was in profit but the bar still not yet reach 7 yet ?

Can you told me what is the problem , here is the picture i capture just now .

Thank you .

Steven.

Files:
Mladen Rakic
114075
Mladen Rakic  
stevenpun:
Hello mladen i very like this ea , but i have problem .

My i know this ea can use it on renko too?

I have set the high low bar to 7 and trail only in profit to true .

Some time the stop loss will move when it was in profit but the bar still not yet reach 7 yet ?

Can you told me what is the problem , here is the picture i capture just now .

Thank you .

Steven.

Steven

Will have to test it on renko (did not test it that way since renko is not standard and I usually do not test non standard ways)

If I get some results will let you know

FxSteven
174
FxSteven  

Ok , hope can get your answer Thank you .

p_tejerina
3
p_tejerina  
JohnnyAmpere:

Is it possible to also add an option so the stop loss only jumps if the candle is in the right direction? In sell trades only move on downward candles and in buy trades only move on upward candles.

I tried adding this option myself but I failed miserably.

Hi mladen,

I wish this could be done also, please. If in a buy order, stoploss shouldn't move if previous bar is bearish, and stoploss shouldn't move in a sell order if previous bar is bullish.

Thanks in advance.

Mladen Rakic
114075
Mladen Rakic  
p_tejerina:

Hi mladen,

I wish this could be done also, please. If in a buy order, stoploss shouldn't move if previous bar is bearish, and stoploss shouldn't move in a sell order if previous bar is bullish.

Thanks in advance.


If you use default values (HighLowBar set to 1) then previous bar (already closed) is used. In that case even older bar should be used for what you describe, and I don't think it would be good

FxSteven
174
FxSteven  
mladen:


If you use default values (HighLowBar set to 1) then previous bar (already closed) is used. In that case even older bar should be used for what you describe, and I don't think it would be good

Hello mladen ,

i think i am the third request for adding option "check bar direction " for this good ea .

I was using this ea for manual trade about 6 month , i always make a trade before i work and i just use this ea for tailing .

I have set "HighLowBar=4" and "TrailOnlyInProfit=true" , but don't know why the stop loss always move to the minimum distance stop level

when it was in profit .

I try to adding bar check some things like this but not success

extern bool           UseBarDirection = true;
extern int            BarCheck =2;
-------------------------------------------------------------------------------------------
if( !UseBarDirection || ( UseBarDirection && CheckBarDir() ) ) 
-------------------------------------------------------------------------------------------
bool CheckBarDir()
   {
      for (int i=OrdersTotal()-1; i>=0; i--)
   { 
   if (OrderSelect(i, SELECT_BY_POS,MODE_TRADES))    

   if(OrderType() == OP_BUY)
      if(Open[BarCheck] < Close[BarCheck])
         return(true); 

   if(OrderType() == OP_SELL)
      if(Open[BarCheck] > Close[BarCheck])
         return(true); 
     }      
   return(false);
   }

  I add the trade and test it on back test , here is the example some time the stop loss move to minimum stop level and hits the stop loss.

After trend was continue....

HighLowTrailingStop

Hope you can giving a helping hand to check this good ea .

Thank you .

Steven.

Mladen Rakic
114075
Mladen Rakic  
stevenpun:

Hello mladen ,

i think i am the third request for adding option "check bar direction " for this good ea .

I was using this ea for manual trade about 6 month , i always make a trade before i work and i just use this ea for tailing .

I have set "HighLowBar=4" and "TrailOnlyInProfit=true" , but don't know why the stop loss always move to the minimum distance stop level

when it was in profit .

I try to adding bar check some things like this but not success

  I add the trade and test it on back test , here is the example some time the stop loss move to minimum stop level and hits the stop loss.

After trend was continue....


Hope you can giving a helping hand to check this good ea .

Thank you .

Steven.

stevenpun

Without knowing the whole code, I can not tell what is happening

To add comments, please log in or register