Speed up the strategy Tester.....

 

I wanted to know how to speed up the visual backtester beyond 32. 7000 lines of code and with tick data (dukascopy via birt csv2fxt) each trading day is taking about 1.5-2.5 minutes.

I was wondering what could be done to speed this up.

I am using SSD laptop or VPS, quad core intel i5 or i7 processors, 1gig+ free ram, win7 or win2008 64 bit. Mt4 build 509.

I am greatful to even get tick data backtesting and even variable spread backtesting, but i still would like to speed things up if possible to do on my end.

 
4evermaat:

I wanted to know how to speed up the visual backtester beyond 32. 7000 lines of code and with tick data (dukascopy via birt csv2fxt) each trading day is taking about 1.5-2.5 minutes.

I was wondering what could be done to speed this up.

I am using SSD laptop or VPS, quad core intel i5 or i7 processors, 1gig+ free ram, win7 or win2008 64 bit. Mt4 build 509.

I am greatful to even get tick data backtesting and even variable spread backtesting, but i still would like to speed things up if possible to do on my end.

Don't do things every tick that you only need to do once per bar, don't do things once per bar that you only need to do every few bars . . . you can make a huge difference considering these things: https://www.mql5.com/en/forum/144240
 
4evermaat: I wanted to know how to speed up the visual backtester beyond 32.
  1. 32 skips all graphics processing, so your test runs at full (1 core) speed.
  2. Don't do unnecessary stuff. If you're waiting for price to hit a trigger, ignore all ticks until it hits or a new bar starts. Check my CallAgain functions.
 

Thanks for the suggestions, Although apami indicator needs every-tick processing for maximum accuracy, there may be other functions that do not need this. Also, equity-based profit targets and stop losses i would think have to be checked every tick.

Another option would be to use sub-min bars (seconds or ms bars), but I do not know how to do this in mt4. Do you think processing every other tick or every x tick (entire EA or certain functions) would be a decent compromise for "quick-testing" the EA?. We could even do this at certain times of the trading day so that during liquid times when more ticks are present it can be proportional.

Is there anyway to set mt4 tester to use 32 speed as a default in visual mode? This seems to always reset to 26 when terminal is restarted.

edit: running tests with visual mode disabled is much faster. but you dont have the chart reference.

 

Maybe one of those 16-32 core vps ? I don't know personally but I intend to test it out eventually

 
Subgenius:


Maybe one of those 16-32 core vps ? I don't know personally but I intend to test it out eventually

That won't help. Strategy tester use only 1 core.