How Long Should you Backtest a Trading System? - Traders Log (2024)

I am frequently asked how long one should backtest a trading system. Though there’s no easy answer, I will provide you with some guidelines. There are a few factors that you need to consider when determining the period for backtesting your trading system:

Trade Frequency

How many trades per day does your trading system generate? It’s not important how long you backtest a trading system; it’s important that you receive enough trades to make statistically valid assumptions*. If your trading system generates three trades per day, i.e. 600 trades per year, then a year of testing gives you enough data to make reliable assumptions*. But if your trading system generates only three trades per month, i.e. 36 trades per year, then you should backtest a couple of years to receive reliable data.

Underlying Contract

You must consider the characteristics of the underlying contract. The chart below shows the average daily volume of the e-mini S&P:

How Long Should you Backtest a Trading System? - Traders Log (1)

It doesn’t make sense to backtest a trading system for the e-mini S&P before 1999, because the contract simply didn’t exist! In my opinion it doesn’t make sense to backtest an e-mini trading system before 2002 because at that time the market was completely different; less liquidity and different market participants. I believe that a reliable testing period for the e-mini S&P are the years 2002 – 2004.

* What is “statistically valid”?

Recently I received an article from a Ph.D in Statistics. He explained the correlation between the sample size and the “margin of error” in the table below. The bigger the sample is the smaller the margin of error, but usually a sample date of 200 trades should be sufficient. If your trading system generates enough trades, then you should use 500 – 600 trades.

How Long Should you Backtest a Trading System? - Traders Log (3)

For more information visit RockwellTrading.com

How Long Should you Backtest a Trading System? - Traders Log (2024)

FAQs

How Long Should you Backtest a Trading System? - Traders Log? ›

When you are backtesting a day trading strategy (15-minute timeframe or lower), it is usually enough to go back two to three months and start your backtest there. When you are backtesting a strategy on a higher timeframe, you will have to go back 6 to 12 months.

How long should you backtest a trading system? ›

Aim for at least 200 trades in your backtest, but 500-600 offers even greater reliability for informed decision-making. Beware of "Data Fatigue": Excessively long backtests can mislead you by including drastically different market regimes.

How to backtest a trading system? ›

Steps on how to backtest a trading strategy
  1. Step 1: Define the trading strategy. ...
  2. Step 2: Obtain historical data. ...
  3. Step 3: Execute the strategy. ...
  4. Step 4: Track and record results. ...
  5. Step 5: Analyse the results. ...
  6. Step 6: Refine and optimise the strategy. ...
  7. Step 7: Validate the strategy.
Aug 14, 2023

What is a good backtesting result? ›

A well-conducted backtest that yields positive results assures traders that the strategy is fundamentally sound and is likely to yield profits when implemented in reality. In contrast, a well-conducted backtest that yields suboptimal results will prompt traders to alter or reject the strategy.

How long should I backtest Reddit? ›

On the other hand, if you're trading 1-minute, 5-minute, 15-minute, or scalping trades, limit your backtesting to a maximum of 3-6 months. Going beyond this timeframe becomes excessively time-consuming and will not give you any further edge.

What is a good expectancy for a trading system? ›

Generally speaking, a good trading expectancy should be positive and ideally above 0.25%. This means that the expectancy ratio is higher than 1, meaning that traders can expect to make more money on their winning trades than they lose on their losing trades.

What are the risks of backtesting? ›

Risks and Limitations of Backtesting
  • Data snooping bias: Backtesting involves testing multiple strategies on historical data, which can lead to data snooping bias. ...
  • Overfitting: Backtesting allows traders to optimize their strategies based on historical data.

What is a good sample size for backtesting? ›

Evaluating Backtesting Results

When it comes to evaluating the results of your backtest, we can focus on a few important performance and trading metrics. However, it is important to remember that a sample size of at least 30 (ideally 50) trades is necessary to get statistically significant results.

What is the best platform to backtest trading? ›

Top best backtesting software for stocks 2024
  1. Amibroker. Amibroker is a comprehensive and highly customizable backtesting platform that allows traders to develop, test, and optimize their trading strategies. ...
  2. TradeStation. ...
  3. MetaTrader 4/5. ...
  4. NinjaTrader. ...
  5. Backtrader. ...
  6. Quant Rocket. ...
  7. Trade Ideas. ...
  8. MultiCharts.
Apr 24, 2024

How do you backtest accurately? ›

Here's an example of one of the methods:
  1. Navigate to the indicators and trading systems window.
  2. Select the trading system you want to backtest.
  3. Open the trading system and input your test parameters.
  4. Run your test and analyse the results.
  5. Optimise by testing different input parameters (eg stop-loss values and limit orders)

Is TradingView good for backtesting? ›

In summary, TradingView provides powerful tools for both manual and automated backtesting. However, remember that backtesting is just one part of strategy development. Past performance doesn't guarantee future results, so always trade with caution and proper risk management.

Does backtesting really work? ›

This is that a profitable backtest does not prove that a strategy “worked”, even in the past. This is because most backtests do not achieve any kind of “statistical significance”. As everyone knows, it's trivial to tailor a strategy that works beautifully on any given piece of historical data.

What is Overfitting in backtesting? ›

A common mistake that many backtesters make is to rely on a single metric or scenario to evaluate their backtesting strategy. This can lead to overfitting, or fitting the model too closely to the data, resulting in poor performance in new or different situations.

Should you wait for retest trading? ›

Price action may not always be predictable enough and fail to retrace as expected. Such events are known as false breakouts. A premature decision could result in a losing trade, which is why waiting for a retest to validate itself is key.

Which is the fastest backtesting framework? ›

Backtesting.py is a small and lightweight, blazing fast backtesting framework that uses state-of-the-art Python structures and procedures (Python 3.6+, Pandas, NumPy, Bokeh). It has a very small and simple API that is easy to remember and quickly shape towards meaningful results.

What is the backtest limit on TradingView? ›

Please note that the maximum length of historical data per calculation is 2 million bars. If the period used for a backtest covers more than 2 million bars, the strategy will execute on the most recent 2 million bars within the selected period.

How long is the backtest time frame for Tradingview? ›

It is Backtest Calculator For Essential and Plus plan holders, the length of available intraday data is calculated as follows: from now to 6 weeks back multiplied by timeframe(in minutes), i.e. you can go 6 weeks back on the 1-minute chart, 12 weeks back on the 2-minute chart, 30 weeks back on the 5-minute chart, 90 ...

How long should you practice trading? ›

Six months is the quickest; most take longer. If learning part-time, expect to spend a year, or two, or more before making money (not due to luck) trading stocks, forex, crypto, or another asset. See scenarios for how long it takes most people to make consistent money from trading, and why.

Is backtesting good for trading? ›

Past results are never a fool-proof indicator of future performance. Rather, it's part of doing your due diligence before opening a position. Backtesting will help you to establish how volatile an asset class can become and take the necessary steps to manage your risk.

What is the backtest limit on Tradingview? ›

Please note that the maximum length of historical data per calculation is 2 million bars. If the period used for a backtest covers more than 2 million bars, the strategy will execute on the most recent 2 million bars within the selected period.

Top Articles
Latest Posts
Article information

Author: Dan Stracke

Last Updated:

Views: 5696

Rating: 4.2 / 5 (43 voted)

Reviews: 82% of readers found this page helpful

Author information

Name: Dan Stracke

Birthday: 1992-08-25

Address: 2253 Brown Springs, East Alla, OH 38634-0309

Phone: +398735162064

Job: Investor Government Associate

Hobby: Shopping, LARPing, Scrapbooking, Surfing, Slacklining, Dance, Glassblowing

Introduction: My name is Dan Stracke, I am a homely, gleaming, glamorous, inquisitive, homely, gorgeous, light person who loves writing and wants to share my knowledge and understanding with you.