How many years of backtesting do you use for testing stocks?

Discussion in 'Strategy Building' started by helpme_please, Feb 9, 2021.

  1. Dicer

    Dicer

    #11     Feb 10, 2021
  2. No trials is not backtests. It's how many times you fitted the data. Basically the more fits you do, the greater the chance of finding a spurious result, the more data you need. So unlike data points, you want fewer trials. And this particular plot would be different, depending on the underlying Sharpe Ratio.

    Also it definitely isn't the case that having more frequent data reduces the history of data required, since the noise and the parameter variability both scale with the square root of time. If you need 20 years of daily data for statistical significance, you will also need about 20 years of one minute data *

    [the exception clearly is if you have data that is 'too slow' for your trading system; of course an HFT would benefit from having tick data rather than daily data]

    GAT

    * [Technical note] very slightly less because the T-distribution is converging on a normal distribution so the critical value of T falls a tiny amount from 2500 observations to several million.
     
    #12     Feb 10, 2021
  3. %%
    True.
    BUT i still like all the data;
    going back to 1927-37 + 1776...................................................................]Edit=all the data on larger timeframes]
     
    Last edited: Feb 10, 2021
    #13     Feb 10, 2021
  4. ph1l

    ph1l

    #14     Feb 10, 2021
  5. Dicer

    Dicer

    just forget about the graph. The reason why Marcos Lopez form a false strategy theorem is that he wants to raise the awareness of multiple backtest Overfitting.

    There are many ways to calculate the probability of Overfitting, such as deflated sharpe ratio, family wise error rate......,etc.

    however, they don’t define what trial is. Some backtesters sometimes just do a small change on the code while others do a big change. Under this situation, how can they have a same Overfitting probability?

    that’s why deflated sharpe ratio is useless under some scenarios.

    But yes. you should be careful of multiple testing. More importantly, your strategy needs to be explainable, don’t use too many variables and run LASSO to reduce Overfitting.
     
    #15     Feb 11, 2021
  6. Traders should backtest for at least 3-4 years to get reliable data.
     
    #16     Feb 12, 2021
  7. Dicer

    Dicer

    I guarantee: if only backrest 3-4 years, your model must be overfitted unless tick data.
     
    #17     Feb 12, 2021
  8. guowei58

    guowei58

    2K trades to be sure it's not overfitted
     
    #18     Feb 15, 2021
  9. Dicer

    Dicer

    it also depends on the distribution of your trades. If your trades tend to move to particular time frame, for example you backrest 2000-2020 and more than 1.5k trades (>75%) are completed in 2008 and 2020, your ML may not learn the general data structure.
     
    #19     Feb 15, 2021
  10. Dr_Trade

    Dr_Trade

    I think more important than time, is the data you are using for your backtesting. You should take into account different market conditions that can simulate your trading plans.
     
    #20     Feb 18, 2021
    Dicer likes this.