Too many trades.
-
EA closes trades and opens every second without command, how can I stop this
-
Here the project link
https://fxdreema.com/shared/bK1OVNI9d -
Your bot runs on conditions that are often true, you need to limit this by adding/changing conditions... one way would be to add a flag that stopes trades being placed until you want them to be placed.
-
@jstap what flag exactly can I add ?
-
This depends it is very strategy specific, you could use time to prevent, once per bar depending on TF used would restrict trades taken. Simply trade taken switch flag off, when something happens switch it on, and check before taking a trade.
-
@jstap Alright, but I wonder why does it even close the trades just after opening when there's no stop loss or TP or breakeven triggered. The Logic is not adding up..
. -
It is probably as you have a close trades block on each tree, and as this is set to the opposite type it has a green light to reach on many situations, for now delete them and add the close back, maybe on a separate tree when you ensure all else is working.
-
@jstap How will it iclose trades when an opposite trade is triggered when it's connected to a different tree..
At least now it's no longer opening trades and closing trades Immediately, but it closes trades mid trade when there's no trigger, when it should allow trades to run.
-
@jstap I am not sure if I ma really getting, do you mind showing me what you mean by creating an EA with my conditions as an example, so I clearly get you.
-
Is the structure you shared the whole project or just part of it?
-
It's the whole project
-
@l-andorrà
@jstap
It's the whole project -
Closing trade is done from a logic flow, if "this" happens close... you can open and close in 1 tree, but remove the close for now, check that EA is opening as needed, then you can add the close, change the set up and test, you will then find the setup that does what you want when you want. (you can do this on back test)