Да и дальше взаимодействия с Оптимизатором нет никакого. в кеше Оптимизатора по каждому проходу хранятся все стат. Бонусом идет возможность запуска любого прохода из обновленной таблицы стандартными средствами в два щелчка
The Settings[0] = Cache.TesterString(Pos); command sets highly distorted information in Settings[0], although the found optimal value TF=20 is set correctly.
But the very structure of Settings[0] is already destroyed. Even the right border of the interval for TF has been changed from H1 to M12.
In the attached log the Settings[0] line is printed before and after the execution of the above command.
I can't understand why this command distorts theSettings[0]string so much.
Optimisation=1 changed, although it should not be changed
If a GA is selected, but the number of passes is small, the Tester automatically enters the full search mode. That is why opt-file after selecting GA sometimes shows that there was a full overrun. Reading this value is correct.
Further, data structures have been changed for many parameters:
Baza=46 Correct should be: Baza=46|||20|||1|||50|||N
Ranges of non-optimised parameters are not written (exception - bool-parameters) in the opt-file. As a consequence, changing such a range does not affect the generator of the opt-file name. Correct work here.
Applying such "reduced" settings does not violate the previously selected ranges of non-optimisable input parameters.
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Good afternoon!
Is it possible from the script to change the start and end dates of the optimisation period that were set when the script was started?
In this case it would be possible to expand the optimisation options.
Regards, Alexander
Is it possible from the script to change the start and end dates of the optimisation period that were set when the script was run?
Thank you!
You have received an opt file in a byte array. Next, you need to feed it into Cache.
Good afternoon!
The question concerns the Run procedure.
I can't understand why the command: Settings[0] = Cache.TesterString(Pos);
messes up the settings string Settings[0].
Below is the code text, and the data from the log is attached.
Regards, Alexander.
Run(Settings[0]); // Run genetic optimisation on parameter TF
TESTERCACHE<ExpTradeSummary> Cache;
GLOC = MTTESTER::GetLastOptCache(Bytess); // Get opt file into Bytess byte array
CL = Cache.Load(Bytess); // Feed the Bytess byte array into Cache
Print(" GLOC = ",GLOC," CL = ",CL); // Write and read diagnosis
// ProfitNow = Cache[GetMaxProfitPos(Cache)].profit; // Maximum profit https://www.mql5.com/ru/forum/318998/page2#comment_13846951
int NomProchMaxProfit = Cache[GetMaxProfitPos(Cache)].Pass; // Number of the pass with maximum profit
// Cache.GetInputs(IndexMaxProfitRuna,Paramas);
// prWrite2 = Cache.Save(OptFile); // Save the Run result to an opt file in MQL5\Files
// prRead2 = Cache.Load(OptFile); // Read for checking from MQL5\Files
// Print(OptFile+" write = ",prWrite2," read = ",prRead2); // Write and read diagnosis
Pos = GetMaxProfitPos(Cache);
Cache.SaveSet(Pos); // Create a set file of the most profitable pass in MQL5\Files
Print("Pos = ",Pos," NomProchMaxProfit = ",NomProchMaxProfit);
Print("Before Cache.TesterString(Pos) ",PrGenetic," NumPeriod=",NumPeriod,"\nControl Genetics: \n",Settings[0]);
Settings[0] = Cache.TesterString(Pos); // Write new settings to the current settings string
// In the previous command, the Settings[0] string is very ugly, although the TF=20 value is set correctly.
Print("After Cache.TesterString(Pos) ",PrGenetic," NumPeriod=",NumPeriod,"\nControl of genetics: \n",Settings[0]);
// In the previous command the Settings[0] line is very ugly, although the TF=20 value is set correctly.
I don't get it.
Afternoon!
The Settings[0] = Cache.TesterString(Pos); command sets highly distorted information in Settings[0], although the found optimal value TF=20 is set correctly.
But the very structure of Settings[0] is already destroyed. Even the right border of the interval for TF has been changed from H1 to M12.
In the attached log the Settings[0] line is printed before and after the execution of the above command.
I can't understand why this command distorts theSettings[0] string so much.
I can't understand why this command distorts the Settings[0] string so badly.
Please send the opt-file to LS.
Optimisation=1 changed, although it should not be changed
If a GA is selected, but the number of passes is small, the Tester automatically enters the full search mode. That is why opt-file after selecting GA sometimes shows that there was a full overrun. Reading this value is correct.
Further, data structures have been changed for many parameters:
Baza=46 Correct should be: Baza=46|||20|||1|||50|||N
Ranges of non-optimised parameters are not written (exception - bool-parameters) in the opt-file. As a consequence, changing such a range does not affect the generator of the opt-file name. Correct work here.
Applying such "reduced" settings does not violate the previously selected ranges of non-optimisable input parameters.