Recently, we’ve started talking about the 3 keys to a winning trading plan.
Last week, we looked at the first key…
Which is to have your plan in writing.
Today, it’s time to dive into Key No. 2…
And this one is something you absolutely MUST do before ever taking a live trade.
I’m talking about backtesting and forward testing your trading plan.
Now, backtesting means using your plan on historical market data to see how it would have performed historically.
Many platforms support automated backtesting…
But if you don’t have that function available to you, you can simply go through your entry and exit rules manually using the historical data.
Forward testing, on the other hand, refers to testing your plan on the live edge of the market.
Forward testing is often referred to as paper trading… and it’s typically done in a simulated account, or sim account for short.
Sim trading is great because it allows you a chance to learn the particular platform you’re using…
While simultaneously practicing entering, managing and exiting trades according to your plan.
Not only does this build up your experience with using the platform and following your trading plan, but it also builds up your confidence as you begin to see that your plan will actually work.
Of course, if it’s not working, the sim account gives you the opportunity to tweak, rearrange and reorder your plan as necessary without risking real money as you work out the kinks.
Now, there are a few things you should keep in mind when backtesting and forward testing that will help ensure you get the most out of your testing.
The first thing is, whenever you’re backtesting, you want to select historical data that represents the current trading climate as much as possible.
That means that if the market you plan to trade is currently in a period of congestion or range-bound trading, you want to choose a period of historical data that looks roughly the same as the current period.
It’s also critical that you look at the same timeframes that you’ll be trading live when you’re backtesting historical data.
Now, the second important thing to keep in mind when backtesting is that you want to use both in-sample data and out-of-sample data.
Here’s the key to testing with in-sample and out-of-sample data…
You will only actually backtest your plan on the in-sample data.
As you’re backtesting the in-sample data, you will use the results to optimize your settings and strategy…
Then, you’ll run the out-of-sample data and analyze the outcome without influencing any of the optimization of your plan.
So, how do you determine in-sample and out-of-sample data?
It’s pretty simple, really.
Once you’ve identified a period of historical data that you want to use for your backtesting, you will divide that dataset into thirds.
Then, you simply define two-thirds of the period as your in-sample data…
And the leftover third will serve as your out-of-sample data.
For instance, if you chose a time period of 3 weeks as your backtesting data period, you could use the first two weeks as your in-sample data…
Then use the last week of the period as your out-of-sample data.
Now, what happens if you backtest with your in-sample data, optimize your results, then run the out-of-sample data and see low correlation?
(In other words, the out-of-sample data test did not perform as well as the in-sample testing that you optimized.)
Well, it often means that your system is over-optimized…
And it might not perform well in a live market.
In that instance, you’d want to go back to backtesting…
So that you can continue to iron out the details, settings and specifics of your plan.
Once you see a strong correlation between your in-sample results and out-of-sample results, you are in a good position to take your trading plan to the live market.
In a future issue, we’ll discuss more about forward testing your trading plan, as well as the third key to developing a winning trade plan…