Skip to Main Content

|

Backtesting as a Public Service

A lot of traders have asked me why we decided to implement a backtesting engine in TrendSpider. That’s a great question – because backtesting is an interesting thing, to say the least. Let’s start with a definition:

Backtesting is the process of applying a trading strategy or analytical method to historical data to see how accurately the strategy or method would have predicted actual results. (source)

This definition is accurate, but it doesn’t tell the full story. Yes, backtesting is a method to test how your strategy (or any strategy) would have panned out in the past. But there are so many strategies, many of the “cookie cutter” variety, that are being promoted all over the internet –  how do you know which one to test? How do you know if your test is reliable? How do you use it to find trades?

These are all really good questions; but they’re not easy to answer. Let’s take it from the top.

First, what are the benefits of backtesting? Well, obviously, leveraging backtesting might help you identify a strategy to trade. But, in my opinion, the real benefit is helping you identify strategies NOT to trade on.  More on that in a moment.

Second, what are the downsides of backtesting? Well, many, actually. We would be dishonest if we did not address these, first. So let’s do that.

  • Backtesting assumes that you execute all your trades perfectly.
  • Backtesting assumes that there is no price slippage and that bids and asks are tight.
  • Backtesting assumes that you’re as fast as a computer and able to get your trades in at the right prices, every time.
  • Backtesting assumes that you ARE a computer – never getting distracted, never skipping a beat, never missing a chance.
  • Most backtesting tools, including ours, do not contemplate brokerage commissions and fees.
  • Backtesting is very vulnerable to ‘curve fitting’ – which basically means finding a strategy that works on one chart during one timeframe, and doesn’t work otherwise.

Obviously, these are important things to keep in mind when using any backtester. Including TrendSpider’s.

So back to the first point – what are the benefits of backtesting. To me, the benefit is in checking yourself – making sure you are sane, making sure you are being smart.

Take for example this backtest on AAPL, 30 min.

Backtesting example in TrendSpider.

It looks great. The strategy is a common one – buy on a golden SMA cross, sell on a SMA death cross. And it seems to work well.

Backtesting example in TrendSpider.

But then take this result, using the exact same strategy, just this time on KO, 30. Not so hot now, huh? That is because of curve fitting.

Any trader who has been around the block will be able to tell you that every chart is different, they each have their own personality, and they each will respond to different signals.

This is why I consider the inclusion of a backtesting engine in the platform to be a public service.

Many traders, in particular new ones, will try to trade strategies that they have read about on an article or seen in a video on YouTube, blindly. The assumption is that indicators, candlestick patterns, trendlines, etc. all work the same, on all charts – and this is one of the biggest contributors to early losses for new technical traders.

By leveraging in-line backtesting as you flip through charts, you can quickly see how your strategy played out in the past, assuming PERFECT execution. Knowing you will not have perfect execution, seeing the results in a backtester can help you avoid making some mistakes that will cost you money.

So next time you find yourself watching a video on YouTube and thinking “that strategy looks brilliant, I’m going to try that” – don’t rush into it. Test it out and see how it would have worked in the past. Then decide what you will do next.

Hope that helps! Happy trading, everyone.