@moses-2 That is anothr loop beacuse you need to check to past trades in order to condition the following one. This loop should be different from the previous one, though.
@samdream0408 Are you using any automatic translator, maybe? If so, it is not very efficient because some parts are really confusing, I'm afraid. I speak Catalan and Spanish, if that can help.
@cesardefez In that case you need a loop searching for that information. I'm afraid loops are not my field of expertise. Maybe mr roar would be so kind to help?
@balonginkosi-buthelezi Did you try to search for the key word 'martingale' on the search tool? You will find many info about that kind of EAs. By the way, I do not recommend you to use it. It is not successful in the long run.