Tue. Oct 20th, 2020
intellinvestors backtesting

How To Backtest Forex Strategies Correctly

Backtesting is not blasting thirty to fifty trades on your backtesting software and claiming that you have a profitable trading system just because the account balance is on the positive side -- it's a more thorough process than that. In this article, you'll find out how to backtest forex strategies the right way. You'll also find, in the second part of this post, some misconceptions traders have about backtesting.

Backtesting Correctly


Here are six steps you can follow to do your strategy testing correctly:

1. Know the rules of your strategy

Before you begin backtesting, your strategy rules must be crystal clear with you.

Your entry, exit, and risk must be carefully defined. It helps if you write down your rules to avoid wavering decision-making.

It's not that your rules should be etched in stone and is unamenable to change, but you have to make sure that you'll make adjustments when you've proven, through substantial backtesting data, that your strategy is fatally flawed.

know the rules of your strategy

2. Ask yourself: Automate or Trade Manually?

Determine if you're going to be automating your strategy or if you're going to backtest manually.

Are you building an EA, or are you testing out a strategy that requires manual execution?

Why does this matter?

Well, an automated strategy will fire up trades as soon as it receives signals from its algorithm. It doesn't account for fundamental data or the condition of the market.

If you're testing a manual strategy, you know what its limitations are and where it's applicable.

But, if you're experimenting both automated and manual systems, be sure to distinguish which one is which before testing.

Want to backtest manually? Read this.

3. Set the duration or the number of trades

What time frame are you using? Are you backtesting with a daily chart or a five-minute chart?

Like what's stated earlier, you can't claim you're profitable after thirty or fifty trades. You have to put that into context.

What if your system trades the minute chart and it churns out a profit after closing thirty trades in a span of twenty-four hours? Obviously, there are the next few days that might tell a different story.

What if your system trades the daily chart and you're profitable for the first two months of 2014 after forty trades? What about the rest of the year, the next year or the year before? You can't have a shortage of data to underpin your claim -- it should be adequate in a relative sense.

4. Record results

Then, for each trade, record your results on a trading journal or a spreadsheet. When you backtest with a backtesting software, like Forex Tester, you can export your trading results to Excel. And the same goes for the strategy tester in MetaTrader with your backtesting results from an EA.

writing-down-trading-results

5. Analyze the statistics

Now, the beauty of exporting your results to Excel is that you can conduct plenty of analyses.

You can determine the profitability, the success rate, the average time to close a trade, drawdowns, average return, return on a specific period, etc.

Those stats aren't just there to provide you an idea of your strategies performance, but it supplies you with a basis of comparison in case you decide to make major or minor refinements to your strategy.

6. Be grounded with your expectations

Finally, once you deem your strategy is ready for real account trading, you have to remember to be grounded with your expectations.

It doesn't mean that if you managed to get a return of 30% from your backtesting session that it will yield the same results with a live account.

This brings us to the next section of this article, which is...

Misconceptions about Backtesting


1. You'll get the same results with a real account

This echoes what's mentioned above about being grounded with expectations.

Traders often think that just because a backtested strategy yielded a certain return on historical data that it's going to be the same with a real account. Nothing can be further from the truth.

drawing of person with question marks

The market, as you know, is very dynamic and is sensitive to a lot of influences.

So to say that an unchanging strategy will be profitable perpetually in an ever-changing market is somewhat contentious.

2. You'll win all the time

Backtesting is not synonymous to full proofing.

Traders often think backtesting as a way for them to make their system infallible, which is wrong. When you backtest a strategy, it should come with the expectation that some trades are still going to be losers, and that's why determining risk is crucial.

3. It helps you take out emotions in real trading

No, it doesn't.

Backtesting is mostly about understanding the performance of your trading strategy. As much as it can't guarantee the same performance prospectively, it can't take away your emotions when trading real money as well.

The cure for erratic trading behavior is experience. Think about it. When you have plenty of experience about something, whether a new job or an unfamiliar task, it becomes less and less daunting when you improve or get more experienced at it.

emotions in trading

If you haven't traded with a real account before and most of what you've done so far is demo trading or backtesting, then you'll come to grips with different emotions with your real account trading sessions.

Conclusion

So, as you can see, testing your strategies on past price data requires diligence to get the most information. It's not a one-and-done thing, but it's a continuous process that aims to ensure that a trading system is viable.

Where To Go From Here

If you're interested in backtesting your trading strategy, you might want to check out our review for Forex Tester by clicking the button below.

7 thoughts on “How To Backtest Forex Strategies Correctly

  1. These are some good general guidelines for coming up with a personal process to backtest forex strategies. If doing these strategies and coming up with a positive balance is not a good indicator of success, what should someone ideally be looking for when they create their strategies?? How long / how many tests are needed? The market has made some big moves lately, and I imagine it’s caught more than a few people off guard. What do you recommend in order to anticipate and handle these big moves to achieve the most positive outcome? Thanks!

    1. Hi Aly,

      Great questions.  

      Well, you have to be counteractive.  You don’t approach the market and say that you have a foolproof system.  When something unfavorable happens, you must know what to do: hedge, close a trade, set stop losses, etc.  And, by backtesting, you prepare for different scenarios, and the unexpected scenarios should have countermeasures as well.

      Backtesting is not something that creates an infallible strategy, but it helps you understand how your system works.  As for the amount of data you need to backtest, there isn’t a set standard, but what’s crucial is you know what market condition is your strategy most successful.  

      For example, if you backtest a strategy that follows bearish trends on the EUR/USD, how successful was it in detecting and riding those trends throughout a period where, say, the US dollar doesn’t dominate the rest of the other major currencies?  For that, you must have years of data to at least build a credible case for your strategy.

      And, for your third question, the best outcome is always to be on the safe side.  So, if you can’t handle the big moves, then you better stay on the sidelines. 😉

  2. Thank you for the investment advice. I agree it is critical to plan, experiment and learn from experience on paper (so to speak) before in trusting your hard earned money to trading. Planning , experience and wisdom are key to successful trading, reducing the risk and increasing the likely hood of positive gain. Best wishing on your prosperous trading.

  3. Thanks for this informative article, I didn’t know backtesting is a key component of effective trading system development and is accomplished by reconstructing, with historical data, trades that would have occurred in the past using rules defined by a given strategy. And it’s obvious the result offers statistics to gauge the effectiveness of the strategy, I’m happy I came across this post and definitely going to put it to use. 

  4. What an incredibly interesting, informative and in depth article, I have always known that I am not the most organized person in the world but after reading this post, I have to admit that I didn’t fully realize how dis organized I actually was, I have most definitely got to look further into backtesting, I have bookmarked your website because I have to be honest and say that I’m having trouble following everything, however I simply have to take these lessons on board, thank you so much for sharing. 

  5. This. Is pretty nice to know, im a very serious person and when it comes to my business, i dont joke with it. Some time ago. I read about the importance of using forex tester and i was quite impressed with what i saw, but i needed more information about the whole thin. Comming across this pist have given me better understading as to what backtesting is about and in the process helping me understand better what forex tester would do for me. Thanks for this wonderful post

  6. Thank you for the article, it is useful.

    As for me, backtesting is one of the best ways to check whether the strategy would be profitable in long term perspective. In fact, it is much more accurate than manual testing due to the less impact of trader`s psychology on testing results. It also allows to spend less time and efforts, that is very important for the trader. There are many tools for backtesting both free and paid, but to my mind the most comfortable is Forex Tester and its newest version in particular because it has all the features need while not being overloaded with something would be difficult to deal with, so it would be easy to use it even for the newbie trader.

    By the way, many traders haven`t even tried to backtest their strategies. This seems surprising to me because backtesting is quite easy and affordable now

Leave a Reply

Your email address will not be published. Required fields are marked *