Check max profit and max loss during a trade
-
I have read the comments, but nothing is matching with what i intend to do. During a test of a trading when my strategy goes in loss, I would like to calculate where the trade will arrive at the max profit. Doing this, I can adjust my take profit and which is more profitable. For example, I have take profit of 100pips, and the trade did not arrive to 100pips, but during the check I realise most of the trade arrived at 50pips, knowing this I will change my take profit. I would like to write it on the label write to file. Thanks in advance for your help.
-
Please Help
i tried to do this but it doesn't count the bars since they open the trade, what am doing wrong ???
https://fxdreema.com/shared/UdRM44lyb -
The modify variable block as you have it set modified the variable called "counter" to 0 and the blocks above mean this will happen once per bar for each trade. The variable is never going to increase because the modify block simply sets it to zero each time.
-
Thanks for the reply ,
But how can count the candles from when it opens the position to when it closes it? -
If in the Adjust Variable block you have you put the variable "counter" in the box where you currently have the 0 and under adjust you +1 then the first chain of blocks you have on the left will, on each bar add one to the variable for each trade you have open.
You will then need to produce something to reset the counter to zero when there are no trades. -
Thanks for the reply.
I tried but the block on the left N360 Modify Varibles does not count the candles to me since it opened the trade, or at least it does not communicate it correctly to the N362 write to file block.
What I would like is that since he opens a position, he starts counting candles until he closes the position.
For example, it opens the position candle one closes after five candles, there are five candles.
At this point it tells block N362 write to file to see the highest price of the last 5 candles, and the lowest price of the last 5 candles
