Increase genetic algoritm number of passes


In fast genetic optimization The default number of passes for many step is 10000.

One day I tested mql5 ea from market and I see it can increase number of passes more than 10000 passes(exp 30000).

Now I need get more accuracy in my optimization result. how I can change default number of passes?(please share code sample)

I appreciate your help.

Easy…Strategy Tester / Optimization / Slow complete algorithm (all passes).

Complete algorithm is good idea but its take long more then one week with my poor PC while I set ea step in minimum.

It is not possible through a code determine the number of passes.

You have two options, genetic algorithm (which I recommend) or make all the checks using all values.

Not exist a middle ground, nor is it possible to determine the number of passes, unless “play” with the number of variables until you find the number of passes to your liking and patience.

I do optimizations of up to 6 or 7 days and the results are worth the wait.

Try a different approach!

Instead of optimizing e.g. a period for iMA from 10 … 100 step 1

do the first optimization with period: 10 … 100 step 10 => then search where you can find the best results!

E.g. 10, 20,30 are the three best of all 9 (10,…,100)! Now do the next optimization with 10…40 step 5 - (and so on).

Of course it can happen that you are skipping fantastic results e.g. at period=78 but:+

the genetic optimization has the same problem: you’ll get a local optimum, which might not be the global one.
you should not look for best ‘peaks’ but for more or less ‘flat hills’ as this is more save against market changes!

There is throttling occurring with the tester, as i will run a test a few times with same perimeters and it will read 27000 passes, only to then be throttled down to 8704 after multiple tests.

This makes one feel as though their efforts are being sabotaged. I also tested with just computer resources and it stills shows as 8704, meaning that one is not being throttled due to heavy server usage. I have checked the configuration files for the tester but do not see where amount of passes can be adjusted.

50,000 passes would be ideal, 8704 is unacceptable. The reality is that with the amount of possible combinations, the passes could reach several millions, and still continue going on indefinitely.

The expert tester is state of the art, so why create that and then throw a wrench into right after? With today’s technology and cloud connections, increase the number of passes to 50,000 or more! (as aforementioned i can definitely confirm it is being throttled by Meta trader 5) :frowning:

There is no default. The 10K is the initial estimate. The estimate changes as the run progresses. There is nothing to change, but your code.

Genetic Algorithm is a kind of logic used by many applications.

There is a good article here to understand how Genetic Algorithm works:

Precisely correct!..