Load optimization results programmatically

 
Hi, how can I load optimization results programmatically into the tester for further testing of those results only for a different date period? Thanks
 
Plamen Zhivkov Kozhuharov: Hi, how can I load optimization results programmatically into the tester for further testing of those results only for a different date period? Thanks

Forum on trading, automated trading systems and testing trading strategies

Optimization outputs; "equity dd"

Fernando Carreiro, 2022.03.19 11:23

Yes, it is true that the standard MT5 optimisation reports only displays the percentage drawdown.

EDIT: It does however already report the Recovery Factorwhich you are trying to obtain (Profit/DD$) — "Recovery factor, equal to the ratio of STAT_PROFIT/STAT_BALANCE_DD"

However, if you do have access to the EA's source code, you can add extra logic to produce a separate data file of statistics to your liking (see "Frame" data in Working with Optimization Results).

In this extra "Frame" data, you can store the available Testing Statistics available to you, such as the maximum balance (or equity) drawdown in monetary terms (STAT_BALANCE_DD or  STAT_EQUITY_DD).

You are however, not limited to these available statistics and can obviously calculate your own and store them in the "Frame" data.

The following references may be of use to you:

 
Thank you. Unfortunately, it doesn't explain how to load the optimization results programatically in a sequence or otherwise. It seems longwinded to be saving every frame when there are a bunch of optimization results with input parameters already generated. Custom configuration file can only load one file using ExpertParameters and that must be a single file, not from the actual list of optimisation results...
 
Plamen Zhivkov Kozhuharov: Hi, how can I load optimization results programmatically into the tester for further testing of those results only for a different date period? Thanks
Plamen Zhivkov Kozhuharov #:
Thank you. Unfortunately, it doesn't explain how to load the optimization results programatically in a sequence or otherwise. It seems longwinded to be saving every frame when there are a bunch of optimization results with input parameters already generated. Custom configuration file can only load one file using ExpertParameters and that must be a single file, not from the actual list of optimisation results...

By the way, optimisation results from one testing period can't be reused to continue for a different testing period. That is self-evident.

All you can do is select some from the outcomes from the first optimisation, and rerun them for the second testing period, in order to compare results, and that can be done from the command-line as explained in the referenced documentation.

You will obviously have to build your own data collection and comparison for that.

 

Thank you, Fernando, it makes a bit more sense now.

Do I need to generate individual expert parameters files from the optimisation results which I then can use in the command-line tester? Just can't get my head round how to achieve it..

Reason: