How to properly test a Forex strategy
In this blog, I’ll explain how you should read the metrics to backtest your strategy. This way, you’ll be able to evaluate your strategy and understand how it performs in unseen data.
I have an old blog about metrics, but I will quickly recap it for you. You can either use software or if you log every trade you can make an excel spreadsheet to work out these key metrics more effectively.
Firstly, we have the win rate and the loss rate.
- The win rate is the number of wins divided by the number of trades. Simply the percentage of winning trades.
- The loss rate is the number of losing trades divided by the number of trades.
- the average win is the total dollar profit of the profitable trades divided by the number of profitable trades.
- the average loss is the total dollar or monetary terms lost on the losing trades divided by the number of losing trades
The next two metrics are very important.
- The profit factor is the profit of a profitable trade divided by the total dollars lost on the losing trades.
- The take profit ratio, which is the average win divided by the size of the average loss, again, pretty much the same as the profit factor.
Then here it is the expectancy.
- the expectancy is the win rate times the average win, all divided by the loss rate multiplied by the average loss.
- the drawdown is the percentage drop from the recent equity high to the equity low.
That’s a short recap of the data and the metrics that you need to know.
The first software that I want to show you is Forex Tester 3. I’ve been using Forex Tester 2 for multiple years and this is just an upgraded version. It is a very useful tool in bat testing your strategy. If you use manual trading, you can go through the candle charts looking at support and resistance, plotting and selling in your buys and sells.
All the metrics are down on the left and they are being calculated as you place your strategy in the backtest environment. You can scroll through the price chart by clicking the space bar to pull the next candle in the timeframe. This will help you to see if it aligns with your strategy, and then place your trade. Also, the metrics are updated as you place a trade.
For example, I did a test of 50 trades using the strategy above. In this backtest for August-September, I’ve had 23 profitable trades and 27 losing trades.
I took that data to calculate the win rate and the loss rate so that you can see it clearly.
Remember, these metrics are going to be used in the excel spreadsheet to give a clearer picture of how this strategy could perform.
If the math is not your thing, you can simply scroll down to the bottom and see all these parameters.
Forex Tester 3 is good especially for manual backtesting, but you will want to use the Strategy Tester if you’re using an expert advisor or an MT4.
MetaTrader 4 or MT4 is free for most broker platforms, so you can backtest out of charge.
To test automated trading strategies, go to “view” in the toolbar and open the strategy tester.
Once the test is completed, click on the report and look at the results of that testing purge for your strategy. There you have all the key data and key metrics that we are searching for like the profit factor, the expected payoff, the average profitable trade, the average losing trade, the largest profitable trade, the largest losing trade and the number of consecutive wins against the number of consecutive losses.
A little advice: You need to make sure of the consistency in these numbers. A strategy with a high percentage of winning trades only from long positions could mean that the testing data are not realistic in distribution.
In conclusion, MT4 is very good to analyze automated trading strategies. On the other hand, manual trading strategies are best analyzed using good old-fashioned pen and paper and scrolling one by one through the candles.
I hope you have found this valuable and if you would like to learn more, join me in the Trading Room. I hope to see you there!