Features of the mql5 language, subtleties and tricks - page 71
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
fxsaber:
Discussion of the article "Visualizing Trading Strategy Optimization in MetaTrader 5"
fxsaber, 2018.02.22 08:39
In frame mode, OnInit, OnDeinit, OnTick, OnTrade, OnTradeTransaction and OnTimer are ignored. Only OnChartEvent works.
Of course, because of the OnChartEvent exception, it requires a mandatory check for the frame mode flag.
Where did you get such an impassioned confidence? :-)
How can you be so sure? :-)
From practice, of course.
Then a question. Is Frame Mode a mode that generally refers to Testing or not?
Then a question. Is Frame Mode a mode that generally refers to Testing or not?
Indirectly, it does. Just in this mode, the Expert Advisor may be started in the Terminal only by the Tester.
Ok. And if the Expert Advisor has the OnTick() handler, it will not work in the frame mode?
Imho, we should clarify that the frame handlers are executed by the Terminal itself and all that is usual for testing (OnTick(), OnTrade(), etc.) is passed to testing agents. ) are passed to the testing agents. Hence, the frame mode is a special compound testing mode where Agents interact interact with the Terminal.
So it goes like this...
Forum on trading, automated trading systems and strategy testing
Features of mql5 language, subtleties and tricks
How do you use mql5?fxsaber, 2018.02.22 09:22
Indirectly, it applies. Just in this mode, the Expert Advisor can be run in the Terminal only by the Tester itself.
And why indirectly? For example, normal optimization can also be run only in the Tester.
Ok. And if the Expert Advisor has the OnTick() handler, it will not work in the frame mode?
Imho, we should clarify that the frame handlers are executed by the Terminal itself and all that is usual for testing (OnTick(), OnTrade(), etc.) is passed to testing agents. ) are passed to the testing agents. Hence, the Frame mode is a special compound mode of testing where Agents interact interact with the Terminal.
So it goes like this.
And why indirectly? For example, normal optimization can be run only in the Tester.
Because it is a combat Expert Advisor even in the frame mode. That's the reason why you have to check the frame flag in OnChartEvent, otherwise such a trouble could happen
This seems to be the first time this has been voiced. It means that Market Products creates an unpleasant vulnerability. And it's very hard to bypass this vulnerability. To detect it is the same.
Because this is a combat EA even in frame mode. This is the reason why you need to check the frame flag in OnChartEvent, otherwise this kind of trouble could happen
This seems to be the first time this has been voiced. It means that Market Products creates an unpleasant vulnerability. And it's very hard to bypass this vulnerability. Detecting it is similarly difficult.
However! If this is true, then, imho, it is incorrect work of the Expert Advisor in Testing mode...
Well done you for noticing it!
Forum on trading, automated trading systems and trading strategies testing
Bugs, bugs, questions
fxsaber, 2018.02.27 08:01
Conclusion about EAs on OBJ_CHART
Therefore, it is possible to make any trading Expert Advisor complete by including the appropriate plug-in(example) to make it work (OnTimer + OnTick) on any kind of chart.
SPY OBJ_CHART is defined by CHART_IS_OBJECT.
Forum on trading, automated trading systems and trading strategies testing
Discussion on the article "Managed optimization: the annealing method"
fxsaber, 2018.02.28 08:45
The tester_file is only read if it existed (content doesn't matter) at the time of compilation.
If mq5 is compiled when there was no corresponding file, even its further existence will not be perceived in EX5.
Therefore, if you generate a file for tester_file in OnTesterInit, make sure that you have compiled the Expert Advisor with at least an empty passing file.
In the presence of the tester_file directive, the Optimizer's caches do not work.