Algo Trading Tip - Beware Of Data Changes
OPENING NOTE: I originally wrote this a few years ago, when the CME futures exchange changed some of their ending times for certain markets. This does not happen too often (thankfully!), but when it does it can have a MAJOR impact on your algo strategies.
JUNE 2021 DATA CHANGE: The CME has instituted another data change, getting rid of the 15 minute "rest" period between 4:15 and 4:30 PM (Eastern) for the stock index futures, such as ES, NQ, YM, RTY and EMD. This change adds in 15 extra 1 minute bars per day. Will this impact some of your algo strategies? Maybe, maybe not.
JUNE 2021 DATA CHANGE: The CME has instituted another data change, getting rid of the 15 minute "rest" period between 4:15 and 4:30 PM (Eastern) for the stock index futures, such as ES, NQ, YM, RTY and EMD. This change adds in 15 extra 1 minute bars per day. Will this impact some of your algo strategies? Maybe, maybe not.
With this particular data change, your historical backtest will not change, since the historical data is not being altered. BUT, future results might be impacted by the extra 15 minutes of data. If you use daily data for your strategy, chances are pretty small that this data change will impact you. For daily data, a new high or low made between 4:15 and 4:30 could change calculations, but I don't think this will happen too often.
If you use small bar sizes, say 1 minute to 15 minute, this change could be significant. The extra data will change indicator calculations, for example. And the bad part is you might not know if right away!
One possible alternative is to create a custom session, where data from 4:15-4:30 PM Eastern is excluded. Such a custom session is shown below, and with this custom session, the data looks like it previously did.
If you use small bar sizes, say 1 minute to 15 minute, this change could be significant. The extra data will change indicator calculations, for example. And the bad part is you might not know if right away!
One possible alternative is to create a custom session, where data from 4:15-4:30 PM Eastern is excluded. Such a custom session is shown below, and with this custom session, the data looks like it previously did.
My recommendations for this data change:
1. If you use the .D symbol, don't worry, this change does not affect you.
2. If you use daily bars without the .D symbol, I would not worry too much. Impact will be minimal, if there is any impact.
3. If you use X minute bars, consider using the custom session I describe above (make sure to test it first)
4. Monitor performance of strategies going forward, and if algo starts to have bad performance, realize it MIGHT be due to this data issue.
If you are a Strategy Factory student, feel free to send me specifics and I'll try to assist you.
********************************************************************
SEPT 2015 DATA CHANGE: Effective September 21, 2015 the CME changed the closing time for futures that closed at 5:15 PM ET from 5:15 to 5:00 PM. The CME did this because the volume from 5:00 PM to 5:15 PM just wasn’t that significant.
My initial thought was “no big deal, my strategies hardly ever traded during that time anyhow.”
Turns out, I was wrong. It could be a HUGE deal, depending on your strategies. Here’s the story, and what you can do about it.
At the end of every month, I take a look at how all my strategies performed during the past month. I take a quick look at the equity curve, record a performance metric or two, and then move on to the next strategy. I do this for live strategies, experimental strategies, strategies I am watching (incubating), etc. – I analyze over 100 strategies (and growing!) each month.
So, at the start of October, after the CME data change went into effect, I took a look at a 30-minute Crude oil system I had. Last time I looked at it in the beginning of September, it looked like this:
1. If you use the .D symbol, don't worry, this change does not affect you.
2. If you use daily bars without the .D symbol, I would not worry too much. Impact will be minimal, if there is any impact.
3. If you use X minute bars, consider using the custom session I describe above (make sure to test it first)
4. Monitor performance of strategies going forward, and if algo starts to have bad performance, realize it MIGHT be due to this data issue.
If you are a Strategy Factory student, feel free to send me specifics and I'll try to assist you.
********************************************************************
SEPT 2015 DATA CHANGE: Effective September 21, 2015 the CME changed the closing time for futures that closed at 5:15 PM ET from 5:15 to 5:00 PM. The CME did this because the volume from 5:00 PM to 5:15 PM just wasn’t that significant.
My initial thought was “no big deal, my strategies hardly ever traded during that time anyhow.”
Turns out, I was wrong. It could be a HUGE deal, depending on your strategies. Here’s the story, and what you can do about it.
At the end of every month, I take a look at how all my strategies performed during the past month. I take a quick look at the equity curve, record a performance metric or two, and then move on to the next strategy. I do this for live strategies, experimental strategies, strategies I am watching (incubating), etc. – I analyze over 100 strategies (and growing!) each month.
So, at the start of October, after the CME data change went into effect, I took a look at a 30-minute Crude oil system I had. Last time I looked at it in the beginning of September, it looked like this:
At the beginning of October, it now looked like this:
Whoa!!! What happened?????
Answer: The CME data change screwed up my strategy!!!
Of course, my immediate thought was “oh no, all my strategies are ruined!” It turns out that is not the case, as I’ll explain later. But the bigger question is why is this happening?
This particular strategy trades the 24-hour market, with 30-minute bars. So, the last bar of the day was always from 5:00 PM ET to 5:15 PM ET (a 15-minute bar, but a bar nonetheless). 47 bars defined one full session. When the CME changed the trading time, my data provider (TradeStation) went back and modified their 24-hour session to end at 5:00 PM, not 5:15 PM. This means all the history changes, with one less bar per day. Now I only have 46 bars each day. Can you see how this might possibly be an issue?
What is the impact of having one less bar per day? Well, it depends on your strategy, but here is what happens to a 20-period moving average indicator. As you can see, as time goes on, the moving average shifts more and more. It is very easy to see how this could dramatically impact your trading strategy signals!
Answer: The CME data change screwed up my strategy!!!
Of course, my immediate thought was “oh no, all my strategies are ruined!” It turns out that is not the case, as I’ll explain later. But the bigger question is why is this happening?
This particular strategy trades the 24-hour market, with 30-minute bars. So, the last bar of the day was always from 5:00 PM ET to 5:15 PM ET (a 15-minute bar, but a bar nonetheless). 47 bars defined one full session. When the CME changed the trading time, my data provider (TradeStation) went back and modified their 24-hour session to end at 5:00 PM, not 5:15 PM. This means all the history changes, with one less bar per day. Now I only have 46 bars each day. Can you see how this might possibly be an issue?
What is the impact of having one less bar per day? Well, it depends on your strategy, but here is what happens to a 20-period moving average indicator. As you can see, as time goes on, the moving average shifts more and more. It is very easy to see how this could dramatically impact your trading strategy signals!
So, that is the bad news. What is the good news? Depending on the market you trade, this data change may or may not be a big deal for you. If you trade with daily bars, chances are this will not be a problem. If you day trade the mini S&P, you should be OK because your session ends at 4:15 PM ET. And, of course any product on the ICE exchange (coffee, cocoa, etc.) is not impacted.
Plus, your strategy may not be impacted by this at all. Strategies that use moving averages might be troublesome, but strategies with candlestick patterns might not be impacted.
Finally, your data provider may matter, too. TradeStation chose to eliminate all history of trading from 5:00 – 5:15 PM ET from their “regular” session (don’t worry, the data is still there, you just have to create a custom session to access that “lost” data), but other data providers might have accounted for the changeover differently. CQG, for example, assumes the closing price of a daily bar is the last trade price. Now, that last trade occurs 15 minutes earlier – that might be an issue for you. Really, you need to check with your data provider to see what they did.
In short, you may or may not have to do anything about this data change, but you should definitely check. You might even have to re-test your strategy from scratch. Here is what I did:
Bottom Line: Check all your strategies. See if the data change impacted them. Realize that future performance might change, and this effect is strategy, market, and data provider dependent. Don’t assume you are safe from this or any other seemingly subtle data change. It may be dramatic for you.
Plus, your strategy may not be impacted by this at all. Strategies that use moving averages might be troublesome, but strategies with candlestick patterns might not be impacted.
Finally, your data provider may matter, too. TradeStation chose to eliminate all history of trading from 5:00 – 5:15 PM ET from their “regular” session (don’t worry, the data is still there, you just have to create a custom session to access that “lost” data), but other data providers might have accounted for the changeover differently. CQG, for example, assumes the closing price of a daily bar is the last trade price. Now, that last trade occurs 15 minutes earlier – that might be an issue for you. Really, you need to check with your data provider to see what they did.
In short, you may or may not have to do anything about this data change, but you should definitely check. You might even have to re-test your strategy from scratch. Here is what I did:
- I analyzed performance of all my strategies. If the historical performance changed between my September 1 and October 1 evaluation, then I knew the strategy was impacted by the data change.
- For strategies that had a change in performance, I did one of three things:
- If performance difference was small, I assumed data change was not that significant, and just left the strategy alone. That could be a bad assumption, I realize.
- If change was large, I re-ran my development steps with the new time session for all the history. Basically, I am treating this as a new strategy. If this new analysis looked good, I now treat this as a “new” strategy.
- For cases where the “new” strategy (based on 5:00 PM end time throughout history) looks awful, I am keeping the original strategy, and just accepting the change. I’ll monitor the performance, but not trade it live. How will the strategy perform with the time session change? I don’t know, but if it keeps working in the future, I might just trade it again. I won’t be surprised, though, if the strategy falls apart. After all, the backtest was based on 5:15 PM stop time, and the future will be a 5:00 PM stop time. Why should that strategy still perform the same?
Bottom Line: Check all your strategies. See if the data change impacted them. Realize that future performance might change, and this effect is strategy, market, and data provider dependent. Don’t assume you are safe from this or any other seemingly subtle data change. It may be dramatic for you.
Widget is loading comments...
About The Author: Kevin Davey is an award winning private futures, forex and commodities trader. He has been trading for over 25 years.Three consecutive years, Kevin achieved over 100% annual returns in a real time, real money, year long trading contest, finishing in first or second place each of those years.
Kevin is the author of the highly acclaimed best trading book "Building Algorithmic Trading Systems: A Trader's Journey From Data Mining to Monte Carlo Simulation to Live Trading" (Wiley 2014). Kevin provides a wealth of trading information at his website: http://www.kjtradingsystems.com
Copyright, Kevin Davey and KJ Trading Systems. All Rights Reserved. Reprint of above article is permitted, as long as the About The Author information is included.
Kevin is the author of the highly acclaimed best trading book "Building Algorithmic Trading Systems: A Trader's Journey From Data Mining to Monte Carlo Simulation to Live Trading" (Wiley 2014). Kevin provides a wealth of trading information at his website: http://www.kjtradingsystems.com
Copyright, Kevin Davey and KJ Trading Systems. All Rights Reserved. Reprint of above article is permitted, as long as the About The Author information is included.