running multiple sequential tests - page 4

 
c_rts:
Yes it works. One thing am not sure of though is in the ini file is should it be Model=... or Mode=...
I quoted directly from the MT5 Help file . . .  it says Model
 

Hi we have automated the optimization process via *.bat File like the example. Since last year we have done more than 70,000 optimizations with no problem at all. But since the last two months some of our Reports.xml are coming out empty only with the headers in the first line. 

We have verified the code, the strategy and this error seems to be Random. 

Here I send an example of a configuration.ini file.

 

[Common]

Login=12345679

Password=aaaaaaaaa

[Experts]

AllowDllImport=1

Enabled

[Tester]

Expert=RS-Robots\RS_FrankenBot\MP\Codigo\v0.02\RS_FrankenBot_MP_v0.02.ex5

ExpertParameters=RS-Tester\1003500\D_1003940_1117.set

Symbol=EURUSD

Period=H1

Login=123456

Deposit=100000

Leverage=1:100

Model=2

ExecutionMode=0

Optimization=2

OptimizationCriterion=6

FromDate=2004.01.01

ToDate=2010.12.31

ForwardMode=4

ForwardDate=2010.01.01

Report=RS-SalidaO\XLSX\1010000\O_1010425_105_FWT_1117.xml

ReplaceReport=0

UseLocal=1

UseRemote=1

UseCloud=0

ShutdownTerminal=1 

 

Does any buddy know about this problem.

Kind regards,

Sergio. 

Documentation on MQL5: Standard Constants, Enumerations and Structures / Environment State / Running MQL5 Program Properties
Documentation on MQL5: Standard Constants, Enumerations and Structures / Environment State / Running MQL5 Program Properties
  • www.mql5.com
Standard Constants, Enumerations and Structures / Environment State / Running MQL5 Program Properties - Documentation on MQL5
 
catuso:

Hi we have automated the optimization process via *.bat File like the example. Since last year we have done more than 70,000 optimizations with no problem at all. But since the last two months some of our Reports.xml are coming out empty only with the headers in the first line. 

We have verified the code, the strategy and this error seems to be Random. 

Here I send an example of a configuration.ini file.

 

Does any buddy know about this problem.


If you are doing exactly the same as you did before and it is no longer working then this suggests a bug has been introduced in a recent release,  you should report this to the Service Desk.
 

"RaptorUK:

If you are doing exactly the same as you did before and it is no longer working then this suggests a bug has been introduced in a recent release,  you should report this to the Service Desk."

 

 

 

Thank you for the answered. I have found a small advance on the subject; The optimizations are done in "Open Prices Only" because of the great speed and acceptable precision. If I change this to "1 OHLC" the error disappears.  

 
catuso:

Thank you for the answered. I have found a small advance on the subject; The optimizations are done in "Open Prices Only" because of the great speed and acceptable precision. If I change this to "1 OHLC" the error disappears.  
That will be helpful information to pass onto the Service Desk,  if there is indeed a Bug t might explain why it was missed.
Get in touch with developers using Service Desk!
Get in touch with developers using Service Desk!
  • www.mql5.com
We therefore attach great importance to all user reports about issues in our programs and try to answer each one of them.
 

I tried to use the batch mode and its is not working . Have any once used it in recent times or help in finding the error pls.

batch file


"C:\Program Files (x86)\MetaTrader - AxiTrader02\terminal.exe" /config:C:\Users\nitin\Desktop\myconfiguration2.ini


ini file.


[Common]

Login=477349

Password=dddd

[Experts]

AllowDllImport=1

Enabled

[Tester]

Expert=\Moving Average.ex4

ExpertParameters=MovingAverage1.set

Symbol=EURUSD

Period=H1

Login=477349

Deposit=100000

Leverage=1:100

Model=1

ExecutionMode=0

Optimization=0

OptimizationCriterion=0

FromDate=2010.01.01

ToDate=2010.12.31

ForwardMode=0

ForwardDate=2010.01.01

Report=opti-eurjpy.xml

ReplaceReport=1

UseLocal=1

UseRemote=1

UseCloud=0

ShutdownTerminal=1

 
nitinjain04:

I tried to use the batch mode and its is not working .

What do you mean by "not working?"

nitinjain04:

Have any once used it in recent times

Yes. I use it all the time; however, I use it with MT5. So, it's possible your issue is with MT4.
 

FYI

This thread helped me a lot, personally I like to run multiple runs of optimisation and then move onto another pair as I tend to use 5/6 pairs at smaller risk amounts to even out bad weeks etc.  As such with a little help from chat GPT I run this bat file to do this without having to run tons of different ini files or long scripts to do this.  My particular setup does use /portable mode and also powershell to adjust the line which dictates the pair before starting the test.

@echo off
echo Startscript to start MT5 optimization/backtester automated.
set "iniFile=D:\MT5Tester2\YOUR EA INI FILE HERE.ini"

:: Define the list of currency pairs to loop over, ensure there is a space between pairs.
set "pairs= EURUSD GBPUSD USDJPY AUDUSD USDCAD NZDUSD USDCHF "

:: Loop over each currency pair
for %%p in (%pairs%) do (

    :: Set the currency pair in the ini file
    powershell -Command "(Get-Content \"%iniFile%\") -replace 'Symbol=.*', 'Symbol=%%p' | Set-Content \"%iniFile%\""

    :: Run the tests 5 times for the current currency pair
    for /L %%i in (1,1,5) do (
        echo Pair: %%p, Iteration: %%i
        echo %date% - %time%
        D:\MT5Tester2\terminal64.exe /portable /config:"%iniFile%"
        echo %date% - %time%
    )
)

echo "Finished!"
PAUSE
Files:
start_mt.zip  1 kb
 
@Stefan Marjoram #:FYI

This thread helped me a lot, personally I like to run multiple runs of optimisation and then move onto another pair as I tend to use 5/6 pairs at smaller risk amounts to even out bad weeks etc.  As such with a little help from chat GPT I run this bat file to do this without having to run tons of different ini files or long scripts to do this.  My particular setup does use /portable mode and also powershell to adjust the line which dictates the pair before starting the test.

Improperly formatted code edited by moderator. Please always use the CODE button (Alt-S) when inserting code.

Code button in editor