Orometra
Analyze my results

Guide

Genetic or complete optimization in MT5: which one to use

When you optimize in MT5 you choose between testing every combination or letting a genetic algorithm hunt for the best ones. The choice does not only change how long you wait: it changes what you can conclude from the results.

Complete optimization

The slow complete algorithm tests every combination in your ranges. With 3 parameters of 20 values each that is 8,000 passes; with 5, 3.2 million. Its advantage is that the map is whole: you can see how the result changes as each parameter moves, and whether the best zone is wide or a lone point.

Genetic optimization

The fast genetic algorithm starts with random combinations, keeps the ones that score best on your criterion and crosses and mutates them to breed the next ones, generation after generation, until they stop improving. It can find good zones in a fraction of the time, but it does not test everything: it concentrates where the criterion is high and barely visits the rest.

Why the genetic search makes overfitting easier

The algorithm actively hunts for the combination that scores highest, and that hunt also rewards the one that got lucky. It also leaves the map in pieces: around the best pass there may be few tested neighbors, and without them you cannot know whether you are on a plateau or on a peak. That is why, with the genetic search, the top row deserves even less trust.

Which one to choose

If the complete search fits in a reasonable time, use it. If not, before switching to the genetic one, see whether you can shrink the problem: drop parameters that barely matter, widen the step or trim absurd ranges. Fewer combinations is not only faster: it also gives chance fewer opportunities to win. If you still need the genetic search, use it to explore: find the promising zone and then optimize that zone with the complete search and a narrower range.

How much was explored

Compare the number of passes with the total number of combinations in your ranges: if the genetic search ran 5,000 out of 3 million, it has seen less than 0.2%. Orometra works this out if you also give it the .set with your ranges, and with genetic searches it is more cautious: it does not invent neighbors that were never tested, and it tells you so.

Common mistakes

Next step

Drop the XML of your optimization, complete or genetic, into Orometra. It takes into account how much of the space was tested, is more cautious when the search was genetic, and tells you whether there is a stable zone behind the best pass or just a lucky point.

Analyze my results How Orometra decides →