Discussion of article "The Use of ORDER_MAGIC for Trading with Different Expert Advisors on a Single Instrument" - 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
New article Use of ORDER_MAGIC when trading with different EA trading programs on a single instrument has been published:
By Nikolay Demko
Hello!
Are the virtual positions described in this article still valid or not?
https://www.mql5.com/en/articles/112
After all, you can select a position via SelectByMagic and use it as a reference. The article is 5 years old, that's why I'm asking.
Hello!
Are the virtual positions described in this article still valid or not?
https://www.mql5.com/en/articles/112
After all, you can select a position via SelectByMagic and use it as a reference. The article is 5 years old, that's why I'm asking.
Thanks for the answer!
I am not interested in Forex as well as MT4.... ) I trade on FORTS.
I don't quite understand you.
1. What happens if I open a long with one magik and then open a short with another? I need two multidirectional positions with different magiks to appear, and at the exchange the position is equal to zero.
2. What happens if I open a long with one magik, and then open another long with another and then open a third long with the first magik? There should be two positions with volumes 2 and 1 respectively. How will it be in practice?
Thank you for the answer!
I am not interested in Forex as well as MT4.... ) I trade on FORTS.
I don't quite understand you.
1. What happens if I open a long with one magik and then open a short with another? I need two multidirectional positions with different magiks to appear, and at the exchange the position is equal to zero.
2. What happens if I open a long with one magik, and then open another long with another and then open a third long with the first magik? There should be two positions with volumes 2 and 1 respectively. How will it be in practice?
Here you need to understand that in reality will be carried out exactly the accounting system that is implemented on the server, if it is FORTS, then netting.
The article describes a relatively simple way of adapting hedge strategies to netting (as an example).
And it is shown on the fingers that in the end there is no difference in the choice of accounting system for profit. Since one system is convertible to another.
If you have a hedge strategy and you need netting accounting, I recommend to adapt the strategy itself to netting, it will be more reliable.
Besides, such adaptation may reveal some pitfalls of the strategy not seen in hedging.
If everything is as you say, then when netting, tying the magik to a position makes no sense. And then it is not clear why it was made 5 years ago, when there was no support for hedge accounting system in MT5. Something is wrong here... Either I don't understand, or there is something unspoken. That's why I asked with concrete examples.
I need to implement a portfolio of strategies on one account and on one instrument. The idea of several sub-accounts is rejected. Of course, I need to emulate a hedging system since MT does not do that (unlike other algo-trading programmes).
If everything is as you say, then when netting, tying the magik to a position makes no sense. And then it is not clear why it was made 5 years ago, when there was no support for hedge accounting system in MT5. Something is wrong here... Either I don't understand, or there is something unspoken. That's why I asked with concrete examples.
I need to implement a portfolio of strategies on one account and on one instrument. The idea of several sub-accounts is rejected. Of course, it is necessary to emulate the hedging system since MT does not do that (unlike other algo-trading programmes).
You are considering the platform's capabilities in a narrow connection to your tasks. In MT5 there is a concept of position magik and there is a concept of order magik, the position magik coincides with the magik of the first order in the position.
To solve your task you need order mags, for other positions mags of positions are also useful.
If you need to implement a portfolio of strategies, you have chosen the right article, understand what it is all clearly written there.
You are considering the capabilities of the platform in a narrow connection to your tasks. In MT5 there is a concept of position magik and there is a concept of order magik, the position magik coincides with the magik of the first order in the position.
To solve your task you need order mags, for other positions mags of positions are also useful.
If you need to implement a portfolio of strategies, you have chosen the right article, understand what it is all clearly written there.
Such clever thoughts come to mind that it would be nice to have a ready-made MQL5 function that would produce a list of trades that make up the current open position. I mean netting. Then one could always know which trades and with which Magic are present in the position at the moment. Now, if one Expert Advisor with one Magic opened a position, the second Expert Advisor with the second Magic added to the position, then the trader closed a part of the position with his hands and there is no way to know which Magic has been bitten off.