MT4 EA - Should I get it rewritten in MQL5? - If so, why?

 

Hey everybody

 I have got an EA made for MT4. But after reading up on the articles in here I have been wondering if it would be a good idea to get it rewritten in MQL5? But im just not sure whether or not it with make my EA better, or provide other advantages? 

My EA is based on a support/resistance and standard MACD setup?

I would love you opinions?

Best Regards

Andreas 

ffandreas(a)gmail.com

 

It depends if you want to enhance it. You can add more calculations to MQL5 programs, and more easily.

For your EA, if you decided to try and add S/R from additional timeframes, or to trade and analyze more than one pair, this might be a situation you want to consider the new language. MQL5 is superior for adding flexibility to the life cycle of your project.

You should analyze the profitability of the EA as it stands. If you are satisfied, leave it in MQL4 and live life. :) 

But if you want to go further, it's totally worth it. 

 
Lugner:

It depends if you want to enhance it. You can add more calculations to MQL5 programs, and more easily.

For your EA, if you decided to try and add S/R from additional timeframes, or to trade and analyze more than one pair, this might be a situation you want to consider the new language. MQL5 is superior for adding flexibility to the life cycle of your project.

You should analyze the profitability of the EA as it stands. If you are satisfied, leave it in MQL4 and live life. :) 

But if you want to go further, it's totally worth it. 

Yes, write your EA in MT5 because the backtesting is a lot more accurate. The mass optimization in parallel is also a great tool. Use the backtesting & optimized results obtained from MT5 and put them back into MT4. Don't use MT5 because it does not allow you to hedge. It also does not allow you to open multiple trades with different stop loss and take profit. So exploit MT5 as it is a great trading system development tool. Continue to use MT4 because you don't have all these crazy restrictions of MT5 i.e. order centric and etc.  
 
waterhorse:
... Don't use MT5 because it does not allow you to hedge. It also does not allow you to open multiple trades with different stop loss and take profit. So exploit MT5 as it is a great trading system development tool. Continue to use MT4 because you don't have all these crazy restrictions of MT5 i.e. order centric and etc.  

The subject of order management deserves a second look - specifically at stops and "hedging".

I want to start by saying all of this behavior can be emulated no matter the conditions from which we start. Imagine you want to "ease out" of a signal which has earned profit. We have to engineer the mechanism for generating partial closes. There is no mechanism built in for the partial closing of trades in MQL4 or MQL5.

Examining SL and TP. we can say they are no more than pending orders. Our programs can decide the appropriate times to consider placing these pending orders. This can effectively remove any question of limitations in MQL5 on that matter. So in the above example, partially closing a position can be solved by defining our own order type "take partial profit". Hopefully you follow my explanation here (if not I will link an article).

But what of the limitations in "position-centric" trades? Similar to how we can solve the limitations on "multiple stops, multiple targets," we can expand and define the terms in opening orders without necessarily "closing" current trades. The fact remains the same, net volume and change in equity per tick on the symbol will behave just the same as it would in MT4. The only difference is we have the responsibility to internally define the individual "trades" as we worked with in MQL4.

That issue is thoroughly discussed in this article. https://www.mql5.com/en/articles/217 It solves more than hedging trades on a pair. The article discusses the management of many trades, from many systems all on the same symbol. It also implements the above logic on SL and TP orders.

There are plenty of resources (some better than others) on this site which explore the techniques of working with the new way. https://www.mql5.com/en/articles/211 Furthermore, theres an article for getting your MT5 EA to tell your MT4 account what to do. https://www.mql5.com/en/articles/189

I hope this better informs opinion on MQL5. 

Creating Multi-Expert Advisors on the basis of Trading Models
  • 2011.01.18
  • Василий Соколов
  • www.mql5.com
Using the object-oriented approach in MQL5 greatly simplifies the creation of multi-currency/multi-system /multi-time-frame Expert Advisors. Just imagine, your single EA trades on several dozens of trading strategies, on all of the available instruments, and on all of the possible time frames! In addition, the EA is easily tested in the tester, and for all of the strategies, included in its composition, it has one or several working systems of money management.