{"id":1022237,"date":"2022-11-03T12:08:22","date_gmt":"2022-11-03T19:08:22","guid":{"rendered":"https:\/\/www.tradingheroes.com\/?p=1022237"},"modified":"2024-03-29T21:42:00","modified_gmt":"2024-03-30T04:42:00","slug":"how-long-should-you-backtest","status":"publish","type":"post","link":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/","title":{"rendered":"How Long Should You Backtest a Trading System?"},"content":{"rendered":"<p>This is a common question that new traders ask, but there isn't one simple answer. In this post, I'll break down how to figure out exactly how long you should test a trading system.<\/p>\n<p><strong>As a general rule, you should backtest a trading system for as long as it takes for you to have confidence to trade the system with real money.\u00a0<\/strong><\/p>\n<p><em>In other words, it depends on a few different factors.<\/em><\/p>\n<p>Let's dive into what you should know about backtesting and how long you should do it.<\/p>\n<p>It all begins with defining our terms&#8230;<\/p>\n<h2>The Definition of &#8220;Long&#8221;<\/h2>\n<p>The first thing that I have to clarify is the what is meant by &#8220;long&#8221; because there can be some confusion here.<\/p>\n<p>There are different interpretations of this word, so here are the definitions that I'm going to cover in this post.<\/p>\n<ul>\n<li>Length of time spent backtesting<\/li>\n<li>Amount of historical data used<\/li>\n<li>Number of backtested trades<\/li>\n<\/ul>\n<p>When we look at the 3 definitions, we realize that &#8220;long&#8221; can mean entirely different things.<\/p>\n<p>So I'll address each one to clear up any confusion, and show you which ones really matter.<\/p>\n<h2>Length of Time Spent Backtesting<\/h2>\n<p><strong>Like with many things in life, the amount of time that you spend on backtesting isn't an indicator of the quality of work that was done during that time.<\/strong><\/p>\n<p>Therefore, the idea that you have to spend a minimum amount of time backtesting is not useful.<\/p>\n<p>In an extreme example, you could backtest for 4 months, but only have 2 backtested trades.<\/p>\n<p>That wouldn't tell you anything about how <a href=\"https:\/\/www.tradingheroes.com\/trading-strategy-profitable\/\">profitable the trading strategy<\/a> is.<\/p>\n<p><strong>So when you're looking for a minimum amount of <a href=\"https:\/\/www.tradingheroes.com\/backtest-trading-strategy-forex-no-coding\/\"  data-wpil-monitor-id=\"88\">backtesting to prove a trading strategy<\/a>, you need to throw out the idea that the act of backtesting should be done for a certain period of time.<\/strong><\/p>\n<h2>Amount of Historical Data Used<\/h2>\n<figure id=\"attachment_1022242\" aria-describedby=\"caption-attachment-1022242\" style=\"width: 1190px\" class=\"wp-caption alignnone\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-1022242 size-full\" src=\"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/backtesting-screen.png\" alt=\"backtesting screen \" width=\"1200\" height=\"601\" srcset=\"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/backtesting-screen.png 1200w, https:\/\/www.tradingheroes.com\/wp-content\/uploads\/backtesting-screen-768x385.png 768w\" sizes=\"auto, (max-width: 1200px) 100vw, 1200px\" \/><figcaption id=\"caption-attachment-1022242\" class=\"wp-caption-text\">Image: <a href=\"https:\/\/www.tradingheroes.com\/best-forex-backtesting-manual-software\/\">NakedMarkets<\/a><\/figcaption><\/figure>\n<p>Another way to measure the amount of backtesting a trader does is to track the amount of historical data used in the test.<\/p>\n<p>In other words, you could backtest a system over 3 years or 30 years of historical data.<\/p>\n<p><em>Obviously, more data is better.<\/em><\/p>\n<p><strong>When you have a lot of historical data, you'll know how your trading strategy would have performed over many different market cycles.<\/strong><\/p>\n<p>This is very important in finding out if you have robust trading strategy or if your trading strategy only works in certain market conditions.<\/p>\n<p>For example, if your trading strategy wasn't tested during the 2007 financial crisis, you wouldn't know what would happen in an extremely volatile market.<\/p>\n<p>So while the amount of historical data you use to do your backtest is an important factor in determining a valid test, there's one more things that you have to consider&#8230;<\/p>\n<h2>How Many Times Should You Backtest a Trading Strategy?<\/h2>\n<p>That brings me to the final backtesting measurement&#8230;<\/p>\n<p><strong>The most useful metric to look at is the total number of backtested trades.<\/strong><\/p>\n<p>If you tested a trading strategy over 300 trades, that would be a lot more reliable than if you tested the strategy over only 10 trades.<\/p>\n<p>That's pretty obvious.<\/p>\n<p><em>But what's not so obvious is the minimum number of trades that will give you confidence in the system you're testing.<\/em><\/p>\n<p>There can be a gray area where you're not sure if you have enough trades in your test.<\/p>\n<p>When you're in doubt, zoom out and consider the bigger picture.<\/p>\n<h3>Think about a day trading strategy&#8230;<\/h3>\n<p>If you only test 100 trades, then you might only have 2-3 months of data. That's not nearly enough to get a good idea of if the strategy is reliable or not.<\/p>\n<p>Even 500 trades might not be enough.<\/p>\n<p>You don't necessarily have to test every single day for the past 20 years, but you should have samples from different market conditions.<\/p>\n<p>There should be trades from:<\/p>\n<ul>\n<li>Volatile markets<\/li>\n<li>Quiet markets<\/li>\n<li>Trending markets<\/li>\n<li>News shock markets<\/li>\n<\/ul>\n<p>The more trades you have from each of these types of markets, the more confidence you'll have in your strategy.<\/p>\n<h3>Now consider a swing trading strategy&#8230;<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1022248\" src=\"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/backtesting-trades-example.png\" alt=\"Backtesting trades screenshot\" width=\"1079\" height=\"390\" srcset=\"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/backtesting-trades-example.png 1079w, https:\/\/www.tradingheroes.com\/wp-content\/uploads\/backtesting-trades-example-768x278.png 768w\" sizes=\"auto, (max-width: 1079px) 100vw, 1079px\" \/><\/p>\n<p>With a swing trading strategy, you might have a relatively low number of trades in your backtest.<\/p>\n<p>For example, let's say that you backtested the <a href=\"https:\/\/www.tradingheroes.com\/rsi-divergence-explained\/\" target=\"_blank\" rel=\"noopener\">RSI Divergence trading strategy<\/a> on the daily chart of the EURUSD.<\/p>\n<p>With this trading strategy, you might only get 25 trades over 20 years.<\/p>\n<p>So does that mean that you throw out the strategy, even if it was profitable?<\/p>\n<p>Of course not.<\/p>\n<p>But you might not have enough confidence in it to trade it live.<\/p>\n<p><strong>In that case, it's important to forward test the strategy until you get to a point where you're confident that the strategy works.<\/strong><\/p>\n<p><a href=\"https:\/\/www.tradingheroes.com\/forex-forward-testing-guide\/\" target=\"_blank\" rel=\"noopener\">Forward testing<\/a> will take some time.<\/p>\n<p>But it's the best way to gain confidence, when you have only have small amount of data.<\/p>\n<p>You could also test the strategy on other markets and timeframes.<\/p>\n<p>If you find other instances where the strategy works, that can also give you more validation that the strategy is reliable.<\/p>\n<h2>The 100 Trades Myth<\/h2>\n<p>There's a meme on the internet that you need a minimum of 100 <a href=\"https:\/\/www.tradingheroes.com\/minimum-backtesting-trades\/\">backtested trades<\/a> to prove that a strategy works.<\/p>\n<p><em>That's simply not true.<\/em><\/p>\n<p>100 trades is nice number of trades to have.<\/p>\n<p>But again, the number of trades you have in a test only tells you part of the story.<\/p>\n<p>Here's what you need to know about the 100 trades myth&#8230;<\/p>\n<p><iframe loading=\"lazy\" title=\"YouTube video player\" src=\"https:\/\/www.youtube.com\/embed\/NU6NYkKhksU\" width=\"840\" height=\"450\" frameborder=\"0\" allowfullscreen=\"allowfullscreen\"><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">?<\/span><\/iframe><\/p>\n<p><strong>The biggest issue with setting a blanket minimum number of trades is that it doesn't take into account the timeframe being tested and the behavior of the specific market.<\/strong><\/p>\n<p>Some statistics professors might tell you that you need a minimum of 30 trades to prove that a trading strategy works.<\/p>\n<p>Others will say 500 trades.<\/p>\n<p>In all fairness, that's a good place to start, from a strictly mathematical point of view.<\/p>\n<p>But in reality, there's a lot of variability between markets, market cycles and trading systems.<\/p>\n<p>What worked in one market or cycle probably won't work in another.<\/p>\n<p>That's why you should be conscious of all of the factors, not just the number of trades alone.<\/p>\n<h2>Final Thoughts<\/h2>\n<p>So that's what you need to know about how long you should backtest.<\/p>\n<p>There isn't one simple answer to this question.<\/p>\n<p><strong>On the surface, you could say that you should have as many backtested trades as possible, over as long a historical period as possible.\u00a0<\/strong><\/p>\n<p>But you have to take into account the nuances.<\/p>\n<p><em>You need to consider your trading strategy, your goals and your level of confidence in your testing.<\/em><\/p>\n<p>Not to worry though, once you start backtesting, you'll get a feel for what's reliable and what's not.<\/p>\n<p>Just get started.<\/p>\n<p>Learn more about backtesting <a href=\"https:\/\/www.tradingheroes.com\/category\/backtesting\/\" target=\"_blank\" rel=\"noopener\">in these posts<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Learn the reality of backtesting trading strategies and how long you should test each strategy. It&#8217;s probably not what you think. <\/p>\n","protected":false},"author":2022,"featured_media":1022468,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[201630],"tags":[201655],"class_list":["post-1022237","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-backtesting","tag-backtesting-for-beginners","generate-columns","tablet-grid-50","mobile-grid-100","grid-parent","grid-33"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>How Long Should You Backtest a Trading System? - Trading Heroes<\/title>\n<meta name=\"description\" content=\"Learn the reality of backtesting trading strategies and how long you should test each strategy. It&#039;s probably not what you think.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How Long Should You Backtest a Trading System? - Trading Heroes\" \/>\n<meta property=\"og:description\" content=\"Learn the reality of backtesting trading strategies and how long you should test each strategy. It&#039;s probably not what you think.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/\" \/>\n<meta property=\"og:site_name\" content=\"Trading Heroes\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/tradingheroes\" \/>\n<meta property=\"article:published_time\" content=\"2022-11-03T19:08:22+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-03-30T04:42:00+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/PERIOD.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1920\" \/>\n\t<meta property=\"og:image:height\" content=\"1080\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Hugh Kimura\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@tradingheroes\" \/>\n<meta name=\"twitter:site\" content=\"@tradingheroes\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How Long Should You Backtest a Trading System? - Trading Heroes","description":"Learn the reality of backtesting trading strategies and how long you should test each strategy. It's probably not what you think.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/","og_locale":"en_US","og_type":"article","og_title":"How Long Should You Backtest a Trading System? - Trading Heroes","og_description":"Learn the reality of backtesting trading strategies and how long you should test each strategy. It's probably not what you think.","og_url":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/","og_site_name":"Trading Heroes","article_publisher":"https:\/\/www.facebook.com\/tradingheroes","article_published_time":"2022-11-03T19:08:22+00:00","article_modified_time":"2024-03-30T04:42:00+00:00","og_image":[{"width":1920,"height":1080,"url":"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/PERIOD.jpg","type":"image\/jpeg"}],"author":"Hugh Kimura","twitter_card":"summary_large_image","twitter_creator":"@tradingheroes","twitter_site":"@tradingheroes","schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/#article","isPartOf":{"@id":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/"},"author":{"name":"Hugh Kimura","@id":"https:\/\/www.tradingheroes.com\/#\/schema\/person\/7224f1a7b68144f87391c62a49d7890a"},"headline":"How Long Should You Backtest a Trading System?","datePublished":"2022-11-03T19:08:22+00:00","dateModified":"2024-03-30T04:42:00+00:00","mainEntityOfPage":{"@id":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/"},"wordCount":1149,"publisher":{"@id":"https:\/\/www.tradingheroes.com\/#organization"},"image":{"@id":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/#primaryimage"},"thumbnailUrl":"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/PERIOD.jpg","keywords":["Backtesting for Beginners"],"articleSection":["Backtesting"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/","url":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/","name":"How Long Should You Backtest a Trading System? - Trading Heroes","isPartOf":{"@id":"https:\/\/www.tradingheroes.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/#primaryimage"},"image":{"@id":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/#primaryimage"},"thumbnailUrl":"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/PERIOD.jpg","datePublished":"2022-11-03T19:08:22+00:00","dateModified":"2024-03-30T04:42:00+00:00","description":"Learn the reality of backtesting trading strategies and how long you should test each strategy. It's probably not what you think.","breadcrumb":{"@id":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/#primaryimage","url":"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/PERIOD.jpg","contentUrl":"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/PERIOD.jpg","width":1920,"height":1080,"caption":"best backtesting period"},{"@type":"BreadcrumbList","@id":"https:\/\/www.tradingheroes.com\/how-long-should-you-backtest\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.tradingheroes.com\/"},{"@type":"ListItem","position":2,"name":"Backtesting","item":"https:\/\/www.tradingheroes.com\/category\/backtesting\/"},{"@type":"ListItem","position":3,"name":"How Long Should You Backtest a Trading System?"}]},{"@type":"WebSite","@id":"https:\/\/www.tradingheroes.com\/#website","url":"https:\/\/www.tradingheroes.com\/","name":"Trading Heroes","description":"Discover Your Grail Trading Strategy","publisher":{"@id":"https:\/\/www.tradingheroes.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.tradingheroes.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.tradingheroes.com\/#organization","name":"Trading Heroes","url":"https:\/\/www.tradingheroes.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.tradingheroes.com\/#\/schema\/logo\/image\/","url":"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/login-logo.png","contentUrl":"https:\/\/www.tradingheroes.com\/wp-content\/uploads\/login-logo.png","width":300,"height":150,"caption":"Trading Heroes"},"image":{"@id":"https:\/\/www.tradingheroes.com\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/tradingheroes","https:\/\/x.com\/tradingheroes","https:\/\/www.instagram.com\/tradingheroes\/","https:\/\/www.linkedin.com\/company\/tradingheroes\/"]},{"@type":"Person","@id":"https:\/\/www.tradingheroes.com\/#\/schema\/person\/7224f1a7b68144f87391c62a49d7890a","name":"Hugh Kimura","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.tradingheroes.com\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/15cd48e3c506e09e7a3b4edf8b221373f1e4e1a9148bbce44c77ff5db1e86693?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/15cd48e3c506e09e7a3b4edf8b221373f1e4e1a9148bbce44c77ff5db1e86693?s=96&d=mm&r=g","caption":"Hugh Kimura"},"description":"Hi, I'm Hugh and I'm an independent trader. Before starting Trading Heroes in 2007, I used to work at the trading desk of a hedge fund, for one of the largest banks in the world and at an IBM Premier Business Partner. Learn more about me here and read more of my articles here.","sameAs":["https:\/\/www.tradingheroes.com\/"],"url":"https:\/\/www.tradingheroes.com\/author\/hughkimura\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.tradingheroes.com\/wp-json\/wp\/v2\/posts\/1022237","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.tradingheroes.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.tradingheroes.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.tradingheroes.com\/wp-json\/wp\/v2\/users\/2022"}],"replies":[{"embeddable":true,"href":"https:\/\/www.tradingheroes.com\/wp-json\/wp\/v2\/comments?post=1022237"}],"version-history":[{"count":2,"href":"https:\/\/www.tradingheroes.com\/wp-json\/wp\/v2\/posts\/1022237\/revisions"}],"predecessor-version":[{"id":1025160,"href":"https:\/\/www.tradingheroes.com\/wp-json\/wp\/v2\/posts\/1022237\/revisions\/1025160"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.tradingheroes.com\/wp-json\/wp\/v2\/media\/1022468"}],"wp:attachment":[{"href":"https:\/\/www.tradingheroes.com\/wp-json\/wp\/v2\/media?parent=1022237"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.tradingheroes.com\/wp-json\/wp\/v2\/categories?post=1022237"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.tradingheroes.com\/wp-json\/wp\/v2\/tags?post=1022237"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}