In Metatrader 5 Strategy Tester you can test an Expert Advisor using different currencies, but you can also automatically test a multi-currency EA without the need of switching the currencies as in MT4.

To test a single currency EA using different currencies you must select the option "All Symbols Selected in Market Watch" in the optimization types selection. You can also select the currencies you want to test in the Market Watch window. In my case, i have selected the Heiken Ashi Expert from the example EA's folder using 5 different symbols. The input parameters were standard:

Multi-Currency Strategy Testing with MetaTrader 5

Note that for each tested symbol, around 10-15MB of history will be downloaded, so if you have selected a lot of symbols it may take a while.

In the optimization results you can see which currencies have performed the best. So using the "All Symbols Selected in Market Watch" option you can automatically test an EA on many symbols, without the need to do it manually.

Multi-Currency Strategy Testing with MetaTrader 5

One of the big advantages of the new Metatrader 5 strategy tester is the option to backtest multi-currency EA's. This was not possible in MT4. The testing and optimization process of an multi-currency expert advisor is the same as with other EA's. Metatester 5 will automatically read the code for multiple-symbol testing. The optimization results ad the equity curve will combine all symbols in one result.

To demonstrate the multi-currency EA testing i have modified the GuruEX03 EA so that it will have 3 currencies. But you can always add more symbols if you want, it's very simple, just copy the code for symbol 4 from previous symbols at the comment "// add more symbols". The EA is a simple moving average crossover trading system. It will enter the market when the slow MA and fast MA are crossed. In the input parameters you can specify all the EA variables. The symbols used in this EA are EURUSD, GBPUSD and USDJPY. You can change them in the line 25-27 of the EA's source code. Download the multi-currency MA crossover EA (.mq5)

Multi-Currency Strategy Testing with MetaTrader 5
I have done a simple 96 step fast optimization and here are the results:

Multi-Currency Strategy Testing with MetaTrader 5
In the log file you can see that the testing process has used all 3 symbols:

Multi-Currency Strategy Testing with MetaTrader 5

5 comments

Anonymous said... @ December 2, 2010 at 7:51 AM

I am interested to know how Money Management and Risk Management is handled with multi-currency EAs. For example, if a strategy risks 2% of account equity on every trade, it is important that the strategy knows the total account equity before entering a trade. In order for the strategy to know total account equity at any given point in time, it must keep a running tab of total PnL for all currency pairs being traded. At any given point in time, Account Equity = Initial Capital + Total PnL (for all currency pairs traded). Is this how Money Management and Risk Management is handled for multi-currency EAs?

Anonymous said... @ December 2, 2010 at 12:59 PM

I should mention that my previous post is regarding how Money Management and Risk Management is handled during during back-testing.

Unknown said... @ September 12, 2012 at 12:28 AM

Thanks for sharing your great blog. Really enjoyed reading about your thoughts and views on this.

Depth of Market Trading

High Frequency Trading France said... @ July 8, 2017 at 12:59 PM

Great ! I had not noticed this option. I'll use it now for backtesting my Ichimoku Ultimate EA for Metatrader 5 !!!

Sunny said... @ June 15, 2018 at 2:17 AM

Does the ea need to be "a multicurrency EA" if tested more than one pair of currency?

Post a Comment