@ladydolares said in Compare orders and close with profit coverage.:
por exemplo, tendência de alta quando o candle está acima de 30. (puramente exemplar)
e quando o candle está abaixo de 30 é uma tendência de baixa.
Existem 2 negociações abertas de compra e venda e a vela está acima de "sma-30". Neste ponto, mais 1 compra deve ser aberta e todas as negociações abertas devem ser fechadas quando houver lucro total.
I believe this logic should not be too planned.
Closing will only happen when you actually make a profit.
The fact that you have one more buy order in profit will not close your orders unless there is a certain profit taking place.
You have to plan very well what you want.
The way you explained it to me I didn't understand, there are elements missing.
bullish trend when the candlestick is above 30. (purely exemplary) But, the candlestick is 30 points above what? A moving average? from which period for example?
There are 2 open buy and sell trades and the candle is above "sma-30". At this point, 1 more buy must be opened and all open trades must be closed when there is a total profit. ----> This will only be decisive and actually happen if you really make a profit.
The order quantity will not matter, as each order has its commission and swap rate, you can find 3 buy orders and 2 sell orders and the sum of the 2 is still negative due to fees, unfortunately I don't believe in exact math on the market.
But if you want to explain it to me in a little more detail, I will try to design the project.
Note: Remembering that I'm not an Expert here, we have many fxdreema experts in this forum, I'm Enthusiast.