I made some changes and code few days back for the weekend. And who says multi-currency back tester can't on MT4, I made it separately so to test the speed, and later for this weekend I'll implement it in the one we have. Including images, on the last line is time, for comparing time needed for optimising.
Satisfying speed for me, around 2 seconds each test multiply timeframes and multiply symbols. That's 2x8x28 for forex = 448 seconds or ~8 minutes for periodical check. Oh I didn't mention, for up to around 300 days is 2 seconds test, for 1000 days is about double. Code is not big, 10k at all the optimiser, and another 40k the file from before.
Oh, and optimise is only for 1 timeframe, simple method, but signals we are able to get from more tframes and would be filtered many losing trades :).
And now in Windows 10 64 bit again I have problems with the arrows, but I'll figure out something. I'll post how will look the panel after the weekend. After all, it is automated trading forum :).
This (last) weekend's days I was comparing some 'Time' for finishing same functions in 'Script' vs 'Expert', and I was surprised, i.e. for same identical functions Expert did same tasks hundreds times slower. As on the previous post images, same thing saved as script it did all in 30 to 90 ms.
My wondering is why that execution differences?
So if it is as is, expert to be so many times slower, I'll move everything to be script.
For the previous images, sums look like big to me too, probably 'Point' value calculation wrong with 1 more digit. So still confused which method is correct, i.e. 5 digits/3 digits/1 digits, with 1 digit more:
/*----- I have in function for calculating profits by points -----*/
profit_pnts = Dev( new_pnts, Point * digit_convert ) ; //<--- Dev is devide (zero fix)
value = Dev( MarketInfo(NULL,MODE_TICKVALUE), MarketInfo(NULL,MODE_TICKSIZE) ) * Point ;
gain_profit = profit_pnts * lots * value ;
profit_pnts = Dev( new_pnts, Point ); //<--- without digits convert
So, still confused which one is correct. For 4/2 digits, I don't have dilemma, but for 5... still confused. But, probably points have to be convert. So this is the difference in time for executing the same code in script (also with fixed calculation :=) ):
... so I think that the original is probably the same one with you.
Thanks for your sharing.
Today (Saturday-free time) I completed indicator for fast optimising strategy before making details in expert (attached "SF_strategy_indicator.mq4"), screenshot how it gives report:
There are comments inside of the file in the beginning where to be written new code and idea, for checking.
The other one included is based on same principle code, script (after finding strategy) for searching same (automatically) but all timeframes for chosen symbol, the best / most profitable, but script capable to trade the written strategy.
The screenshot, it is almost same, but can be enabled "real trading" in Global Variables, all controls are in Global Variables, it does not start by itself to trade. File "SF_script_trader_single.mq4":
I have to do some other jobs tomorrow, so I thinks next weekend I'll make it for all symbols, as "Multi_symbol_auto_trader_selfoptimiser.mq4". I only made the initial look and basic code, the rest next weekend:
I will update.