Discussion of article "Universal Expert Advisor: Integration with Standard MetaTrader Modules of Signals (Part 7)" - page 3

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
Thank Vasiliy for your contribution. I learned a lot. I downloaded all the code but it has a compiling error in file Panel.mqh:
'At' - object pointer expected Panel.mqh 210 39
'At' - object pointer expected Panel.mqh 228 37
Can you please check it?
Hi Amy. I have just completed reading through Vasiliy Sokolov articles. If you are still interested in finding out the solution. Please post the error log here. I recall coming across that error and realised that there is an ".\Panel\Panel.mqh" in declarations in StrategiesList file. Panel.mqh does not exist. Instead, try going to https://www.mql5.com/en/articles/2411 and download the Panel File from there. I believe it has the Panel.mqh file.
This series by Vasiliy's is really good as a framework. I learn't a lot too,but when there are issues with a library, if the author does not offer support, you could be left stuck if you are not a good programmer. Which is the point Alain Verleyen made in your other discussions. But those spending time to share their knowledge and skill here are completely amazing. I am eternally grateful.
The engine is absolutely wonderful, thank you. It is the first OOP MQL5 engine I decided to switch to.
But Manager.OnTick() is unfortunately very slow. Tracing shows almost 100% on it. Testing is very slow on a minute timeframe and with OHLC M1. For 3 years - about 50 seconds. And at the same time the Expert Advisor itself does nothing for testing, I have commented out everything that loads it. That is, it just searches bars.
I really want to optimise the code in Manager.OnTick()
The engine is absolutely wonderful, thank you. It is the first OOP MQL5 engine I decided to switch to.
But Manager.OnTick() is unfortunately very slow. Tracing shows almost 100% on it. Testing is very slow on a minute timeframe and with OHLC M1. For 3 years - about 50 seconds. And at the same time the Expert Advisor itself does nothing for testing, I have commented out everything that loads it. That is, it just searches bars.
I really want to optimise the code in Manager.OnTick()
This is the function from which everything else is launched - of course it will be 100%. Look inside it to see what time is spent on and optimise it. You can publish a screenshot.
The engine is absolutely wonderful, thank you. It is the first OOP MQL5 engine I decided to switch to.
But Manager.OnTick() is unfortunately very slow. Tracing shows almost 100% on it. Testing is very slow on a minute timeframe and with OHLC M1. For 3 years - about 50 seconds. And at the same time the Expert Advisor itself does nothing for testing, I have commented out everything that loads it. That is, it just searches bars.
I really want to optimise the code in Manager.OnTick()
There is nothing surprising here. This speed is comparable to the idle running of a strategy tester. OnTick determines the occurrence of a new tick and opening of a new bar. These operations do not require a lot of resources.
Hi, Vasily.
Thanks for all of your articles.
The Universal Expert Advisor is really impressive in terms of complexity and Software architecture.
For this particular version, I'd like to raise a point in this piece of code here:
Actually, the MacD parameters (15, 32 and 6) are taking no effect here, since CreateSignal() method initializes the MacD signal before the params are updated.
In this case, I'd suggest to split the CSignalAdapter::CreateSignal() method in two parts, where in the first one, the signal is in fact created and returned just like it is, and the second part would be the signal initialization, after all "Signal Dependant" parameters (in this case, PeriodFast, PeriodSlow and PeriodSignal) are set:
And of course, the newly created Init method needs to be called:
Thank you for the great work, and even more for sharing it, Vasily!
Cheers,
Rodrigo Haller
The author has a lot of respect. once again I faced the fact that practically having done something, I found practically the same already done before) as they say everything was invented before us).
One moment I would like to note - in the work of signals to me from the very beginning was wild that takes the weighted average of signals to buy and sell, it does not fit with the logic of decision-making in the canonical form (decision tree, which is already mentioned here) and I did so - the Progenitor of signals contains in addition to the actual list of signals from which the direction is taken (from -100 to 100) slots for signals on AND, ANDNOT, XOR. in this case the usual is OR, not boolean only. All logic of processing of these slots is unambiguous and sewn in the progenitor class. I.e. to construct a strategy you only need to add the main signal to the Expert Advisor and signals to the corresponding logic slots, according to the same principle as originally, i.e. for each up to 64 additional filters. I see this solution as the simplest and easily realisable. If you are interested in the idea and do not understand something, please contact me and I will tell you more.
How it is possible to use class CSignalMACD in script?
I've tried to get signal result just inplace, but always got 0: