Understanding backtesting and overfitting
Backtesting is a crucial tool in the arsenal of traders, investors, and financial analysts. It involves testing a trading strategy or investment hypothesis using historical data to assess its viability and performance. Any time we evaluate an algorithmic trading strategy, we need to answer two questions:
- Does the strategy perform on historical data?
- Will the strategy perform on future data?
The tools to answer the first question are straightforward. We can launch TradeStation backtesting and evaluate results by analyzing the financial metrics we described in Chapter 3.
Answering the second question is a bit more complicated as there is no built-in tool to achieve such a task and the research for this crucial aspect of algorithmic trading is still ongoing.
As you’ll remember from the previous chapter (Figure 3.1), we said that the development process of a trading strategy is iterative, where you refine and improve...