VALYNOXSTRATEGY RESEARCH TECHNOLOGY
AlphaPrimeAlphaPrime
ACADEMY / Markets and trading sessions

Economic calendar backtest: should you filter CPI, FOMC and NFP days?

Run the backtest twice, once with CPI, FOMC and nonfarm payroll days kept and once with entries blocked around them. Keep event days by default with a higher slippage setting for the release bars, and filter only when the difference is large, fits the rule's logic and rests on enough trades.

By · Published · updated · Editorial policy

Contents
  1. Should you filter CPI, FOMC and NFP days from a futures backtest?
  2. Where do you find an economic calendar and which time zone does it use?
  3. What time are US releases in Taiwan?
  4. How much do high-impact releases change volatility and slippage?
  5. How do you tag event days and run the backtest with and without them?
  6. What does a real run look like with event days kept in?
  7. Why is a small sample of event days unreliable?
  8. Frequently asked questions
  9. References

Should you filter CPI, FOMC and NFP days from a futures backtest?

In an economic calendar backtest, run the strategy twice: once with CPI, FOMC and nonfarm payroll days kept, once with entries blocked around each release. Keep event days by default and charge the release bars more slippage. Filter only when the difference is large, follows from the rule's logic and rests on enough trades to mean something.

An economic calendar is a list of scheduled data releases and central bank decisions with their dates, times and an impact rating. An event day is a trading day that holds one of the high-impact releases: CPI (the US consumer price index, the main inflation number), FOMC (the Federal Open Market Committee, the group that sets the US policy rate) and NFP (nonfarm payrolls, the monthly US jobs number). These three move US index futures more than most other releases, which is why traders ask whether to leave them in.

Keeping them in is the honest default because those days will exist when you trade. A backtest that removes them assumes you will stand aside, and that is a rule you must then actually follow, with its own slippage when you flatten before the release. The two runs below show what you are choosing between.

QuestionKeep event daysFilter event days
What the backtest measuresThe rule as it would trade, including release spikesThe rule plus an extra "stand aside" rule you must follow live
Slippage settingHigher for bars inside the release windowNormal, because no entry happens in the window
When it is the right choiceRule holds positions for days; release is one bar among manyRule reacts within minutes of a release and its trades in the window lose after costs
Before trusting the resultAlways valid; it is the base caseEnough window trades that removing two or three would not flip the sign
Keep or filter event days: keeping them suits rules that hold for days, uses higher slippage on release bars and is the base case; filtering suits rules that trade the release spike, uses normal slippage and needs at least 100 window trades Keep or filter event days? Which rule suits which run Keep in Holds for days Higher slippage The base case Filter out Trades the spike Normal slippage Needs 100+ trades Keeping them is the default run. So: filter only on evidence.
The decision is a comparison of two runs, not a yes-or-no rule. The filter earns its place only when the window trades are many and clearly worse.

The rule's holding time decides which column you are in. A trend-following rule on daily bars, one of the five types described in futures algo trading strategies you can backtest, holds through dozens of releases per position, so removing event days changes little except the bars it never traded on. A breakout rule on 1-minute bars fires on the release spike itself, and for that rule the window trades are a separate population worth measuring.

Where do you find an economic calendar and which time zone does it use?

Any of the free calendars lists the same scheduled releases; the detail that matters for a backtest is the time zone the calendar is set to. TradingView's economic calendar, FXStreet's economic calendar and other forex calendars all take their dates and times from the publishing agencies, so the rows agree. A forex market calendar (經濟數據行事曆) is just as useful for NQ or TAIEX futures as for currency pairs, because CPI and FOMC move all of them.

Each calendar shows the release name, the country, the clock time, an impact rating (usually three levels), the previous value, the forecast and, after publication, the actual value. The clock time is shown in whatever time zone the calendar is set to, and that setting is yours to choose. The same US CPI row reads 08:30 with the calendar set to New York, 12:30 with it set to UTC during US summer time, and 20:30 with it set to Taipei. The release has not moved; the label has.

One US CPI release in US summer time reads 08:30 in New York, 12:30 in UTC and 20:30 in Taipei, and all three point to the same single 1-minute bar in the data One release, three labels US CPI, US summer time New York 08:30 UTC 12:30 Taipei 20:30 One bar The release did not move. So: convert to your data's zone.
The same release shows a different clock time depending on the calendar's time zone setting. Only one 1-minute bar in your data is the release bar.

A backtest needs the release converted into the time zone of your bar data before any bar can be tagged. Check which time zone your data file uses first; a file stamped in exchange time and a calendar set to Taipei will put the release on the wrong bar by twelve or thirteen hours. The free futures market hours tool shows each exchange's sessions in your own time zone, which is the same conversion you apply to release times.

For past years, the calendars that let you scroll back are enough for a few years of dates. For a longer history, the publishing agencies keep schedule pages for earlier years: the US Bureau of Labor Statistics for CPI and payrolls, the Federal Reserve for FOMC meeting dates. Take the dates from the actual schedule rather than from a rule like "first Friday", because releases are sometimes moved by holidays or delayed.

What time are US releases in Taiwan?

CPI and nonfarm payrolls come out at 20:30 Taiwan time in US summer and 21:30 in US winter; the FOMC statement comes out at 02:00 or 03:00 the next morning in Taiwan. The US releases keep fixed Eastern times: 08:30 for CPI and payrolls, 14:00 for the FOMC statement. Taiwan has no daylight saving time, so the whole one-hour shift comes from the US side, which moves its clocks forward on the second Sunday of March and back on the first Sunday of November.

ReleaseUS Eastern timeTaiwan time, US summerTaiwan time, US winterTypical schedule
CPI08:3020:3021:30Monthly, around mid-month
Nonfarm payrolls08:3020:3021:30Usually the first Friday of the month
FOMC statement14:0002:00 next day03:00 next dayEight scheduled meetings a year
US release times in Taiwan time: CPI and nonfarm payrolls at 08:30 New York are 20:30 in Taiwan during US summer and 21:30 in US winter; the FOMC statement at 14:00 New York is 02:00 or 03:00 on the next Taiwan day US releases in Taiwan time +1 = the next Taiwan day New York US summer US winter CPI 08:30 20:30 21:30 NFP 08:30 20:30 21:30 FOMC 14:00 02:00 +1 03:00 +1 Summer and winter differ by an hour. So: convert each date on its own.
US release times in Taiwan time shift by one hour with US daylight saving time, and the FOMC statement lands on the next Taiwan date.

Two consequences follow for a Taiwan-based trader. First, the FOMC statement falls on a different calendar date in Taiwan than in the United States, so a tag made by US date will mark the wrong Taiwan day. Second, both the 20:30 and the 02:00 releases arrive after the Taiwan day session has closed, inside what Taiwan traders call the night session and what US stock traders call pre-market or after hours; the guide to after-hours trading hours, liquidity and backtest pitfalls explains why those bars behave differently from regular-session bars. For a US index future the 08:30 release is in the regular futures session but one hour before the stock market opens, so the order book is thinner than it will be at 09:30.

How much do high-impact releases change volatility and slippage?

There is no fixed slippage number for a release; the bars around it trade a wider range on a thinner order book, and the right setting is the one you measure in your own data. Slippage is the difference between the price your rule assumed and the price you actually get. On a normal bar a liquid future fills a stop or market order within a tick or two of the trigger. On the release bar the same order can fill several ticks away.

Two things happen at once. In the minutes before a scheduled release, many liquidity providers pull or widen their quotes because they do not want to hold a position through the number. At the release second, orders arrive in a burst and price jumps through several levels before new quotes appear. A stop order that triggers in that jump becomes a market order and fills at the next available price, which is farther from the trigger than on any normal bar. The range of the bar is a visible record of the move; the depth of the book is the invisible reason the fill is poor.

Illustration of 1-minute bars from 08:00 to 09:30 Eastern on a release day: small bars before 08:30, one very tall bar at 08:30 where a stop order fills well past its trigger, then bars shrinking back by 09:00 Release bars fill far away 1-minute bars near 08:30, illustrative Stop Fill 08:00 08:30 09:00 09:30 The release bar fills far past the stop. So: charge those bars more slippage.
Release bars have a wider range and a thinner order book, so fills land farther from the trigger. The pattern is the same every release; the size is not.

Measure it this way. For each release day in your history, take the high minus the low of the 1-minute bar at the release minute and of the next five bars. Take the same clock minutes on the non-release days of the same month. The ratio between the two averages tells you how much wider the release bars are in your market. Then set the slippage for bars inside the release window as a multiple of your normal slippage, in the same direction as that ratio, and keep the multiple conservative because the range understates how far a stop fills. AlphaPrime (Valynox) charges commission and slippage inside every evaluation with next-bar execution, which is covered on the backtesting page, so the figure you take from the release bars shapes the ranking of every candidate instead of being applied to the winner afterwards.

Hypothetical example

Suppose the 1-minute bars in the hour before a release have an average range of 8 points, and the release minute plus the five bars after it average 48 points, six times as wide. Your normal setting is $10 of slippage per trade. For bars in the release window you raise it to $40 per trade. A rule that takes 60 of its 600 trades inside the window pays an extra $30 on each of those 60 trades, or $1,800 over the run, which is a change of $3 in the average trade across all 600. Whether $3 matters depends on how large the average trade was to begin with.

Bar size changes the question. A rule on daily bars that executes at the next bar's open never sends an order inside the release minute, so for it the release only widens one bar's range and does not touch the fill. A rule on 1-minute or 5-minute bars can be triggered by the release itself, and for it the slippage multiple is the single most important setting in the comparison.

How do you tag event days and run the backtest with and without them?

Tag the bars inside a window around each release, run the unchanged strategy on all bars, run it again with entries blocked inside the window, and compare the average trade after costs and the trade count. An event window is the span of bars you treat as belonging to the release, for example 15 minutes before to 60 minutes after. The steps in order:

  1. Export the calendar for your test period. Keep only the releases you want to test (CPI, FOMC statement, nonfarm payrolls) and their actual dates for each year.
  2. Convert each release time to your data's time zone. Do this per date, because the US daylight saving shift means the same release lands one hour apart in summer and winter.
  3. Mark the bars inside the window. A flag on each bar from 15 minutes before to 60 minutes after the release is a common first choice; widen it later if the range measurement from the previous section shows the market still moving at 09:30.
  4. Run the strategy on all bars with the higher slippage on flagged bars. This is the base run.
  5. Run it again with entries blocked on flagged bars. Exits still follow the rule, so an open position is handled the same way in both runs.
  6. Compare average trade after costs and trade count, not net profit. The second run has fewer trades, so its net profit will differ even if the rule is unchanged; the per-trade figure is the fair comparison.
Six steps from calendar to two runs: export event dates, convert them to bar time, tag the window, run A on all bars, run B with entries off in the window, compare the per-trade result; steps 1 to 3 are done once, steps 4 to 6 for each strategy From calendar to two runs Steps 1–3 once, 4–6 per strategy 123 456 Export Event dates Convert To bar time Tag The window Run A All bars Run B Entries off Compare Per trade
From calendar export to a two-run comparison. Steps 1 to 3 are data work and are done once; steps 4 to 6 are repeated for each strategy.

Tagging bars by date and time is the same mechanic you use for holidays and early closes, and the same traps apply: a release moved by a holiday, a shortened session on the day before one, and a time zone that changes mid-year. The guide to market holidays in backtests and calendar changes covers how to keep a date table that your test can read. For the cost side of the comparison, the method for setting commission and slippage in trading costs in backtests and the average trade applies unchanged.

Hypothetical example

Base run: 600 trades, average trade after costs $45. Blocked run: 540 trades, average trade after costs $52. The 60 trades that the window removed therefore averaged about −$18 each. Sixty trades is a small sample, and if ten of them had been winners of $200 instead of losers, the window average would have been positive. A rule written before the test might say: adopt the filter only if the window trades number at least 100 and their average is below zero by more than the normal round-trip cost. This example fails the count condition, so the filter is noted and not adopted.

What does a real run look like with event days kept in?

A swing rule on daily bars holds through almost every release, so an event-day filter cannot be judged from it, and our own NQ run shows why. The run below tested a stand-in rule built from a standard indicator, an ATR channel as the only entry and exit with no stop, target or filter; it is not an event filter and not the subject of this article itself. It ran on NQ daily bars from 2019-01-02 to 2025-06-30, long and short, one contract, with $20 commission and $10 slippage per trade.

Source: AlphaPrime product engine (CPU), run 2026-10-31. NQ daily bars, 2019-01-02 to 2025-06-30, long and short, 1 contract, $20 commission and $10 slippage per trade.

NumberResult
Net profit (closed trades)$184,055
Max drawdown$108,925
Trades34
Win rate55.88%
Profit factor2.067
Average trade$5,413.38
Time in market95.61%

This candidate is the one the search kept out of 1,024 it tried, chosen for its return against its drawdown. Picking the kept one after the fact flatters it: the best of many tries carries a selection bonus that a new stretch of data would not repeat, so the $184,055 is a description of one past path and not something the rule earned or a reader can expect.

Look at how few times the curve steps: each step is one of the 34 trades, and the positions ran straight through the release days in between.
Look at how few times the curve steps: each step is one of the 34 trades, and the positions ran straight through the release days in between. NQ · daily · 2019-01-02 to 2025-06-30 · CPU engine backtest

What the run does show about event days is in two numbers. Time in market of 95.61% means a position was open on nearly every trading day of the period, so it was open on nearly every CPI, FOMC and NFP day as well. And 34 trades means no split into "window trades" and "other trades" can be read: block entries on the roughly 32 event days a year and perhaps one or two of the 34 entries move by a day, which changes the result by an amount that says nothing about the releases. The max drawdown of $108,925 did not come from any single release day either; on daily bars a release is one bar inside a position held for months.

Look at the trade count next to the net profit: 34 completed trades over six and a half years is the normal count for a daily swing rule, and far too few for any event-day comparison.
Look at the trade count next to the net profit: 34 completed trades over six and a half years is the normal count for a daily swing rule, and far too few for any event-day comparison. NQ · daily · 2019-01-02 to 2025-06-30 · CPU engine backtest

This is the usual situation for a swing strategy, and it is the reason the first section says the filter question belongs to intraday rules. Before testing any NQ rule at a finer bar size, the five settings to set first when backtesting ES and NQ cover the session, roll and cost choices that the two-run comparison depends on.

Why is a small sample of event days unreliable?

Event days are rare, so any statistic about them rests on a few dozen observations, and a filter chosen after seeing such a statistic is mostly fitted to noise. There are eight scheduled FOMC meetings a year and twelve CPI and twelve nonfarm payroll releases, about 32 event days against roughly 220 other trading days. A six-year history holds about 48 FOMC statements and about 72 of each monthly release. A rule that trades once on each event day has a few dozen window trades to judge from.

Event days are rare: in one year there are about 8 FOMC statement days, 12 CPI days and 12 nonfarm payroll days against about 220 other trading days, so any event-day statistic rests on few trades Event days are rare Per year, approximate counts FOMC 8 CPI 12 NFP 12 Other days ~220 About 32 event days a year. So: count window trades first.
Event days are rare, so any event-day statistic rests on few observations, and the uncertainty of an average shrinks only with the square root of the count.

Think of judging a restaurant from eight meals against judging it from four hundred. The average of eight meals swings with one bad night; the average of four hundred barely moves. The same holds for trades. The one formula worth keeping:

average-trade uncertainty = spread of single trades ÷ √N

Here the spread of single trades is how far individual results typically sit from the average, N is the number of window trades and √N is its square root. Going from 48 trades to 400 cuts the uncertainty to about a third, not to an eighth. With 48 window trades and the wide spread that release bars produce, the window average can easily sit on the wrong side of zero by chance.

The second problem is the order of events. If you look at the window result first and then decide to filter, you have chosen the rule that fits this history best out of two, and the next release days have no reason to repeat the pattern. Bailey, Borwein, López de Prado and Zhu (2014) show how quickly a choice made after looking at the results loses its meaning on new data, and Harvey and Liu (2015) propose discounting a result for the number of variants compared before it was chosen. White (2000) gives the formal test for the same problem. The practical fix is the one from the earlier sections: write the trade-count condition and the size of difference you require before you run the comparison, and treat a filter that fails the count condition as untested rather than as rejected.

The next step is one afternoon of work. Take the intraday rule you trade most often, build the release table for the last three years in your data's time zone, measure the range of the release minute against the same minute on normal days, and run the two-run comparison with the slippage multiple that measurement gives. Read the window trade count before you read anything else; if it is under 100, keep the event days in and come back when the history is longer.

Frequently asked questions

Should I exclude FOMC days from my backtest?

Not by default. Keep FOMC days in, raise the slippage setting for the bars around the 14:00 Eastern statement, and run a second backtest with entries blocked in that window. Adopt the filter only if the blocked run has a clearly better average trade after costs and the window held enough trades that removing a few would not flip the sign. For daily-bar swing rules the filter usually changes nothing meaningful, because a position is held through the statement anyway.

What time is nonfarm payrolls released in Taiwan time?

Nonfarm payrolls are published at 08:30 US Eastern time, usually on the first Friday of the month. That is 20:30 Taiwan time while the United States is on daylight saving time (March to November) and 21:30 Taiwan time in US winter. Taiwan does not change its clocks, so the one-hour shift comes entirely from the US side. The exact date can move when the first Friday is a holiday, so take it from the year's schedule.

How much does slippage increase on CPI day?

There is no fixed figure. The 1-minute bar at 08:30 Eastern on a CPI day trades a much wider range than the same minute on a normal day, and the order book is thinner, so a stop or market order fills farther from its trigger. Measure the range of the release bars against normal bars in your own data and raise the slippage setting for the release window by a conservative multiple of that ratio. A rule that never sends orders inside the release minute, such as a daily rule executing at the next open, is barely affected.

Can I use a forex calendar for futures backtesting?

Yes. A forex calendar, an FX calendar and TradingView's economic calendar all list the same scheduled releases from the same agencies, with the same impact ratings. CPI, FOMC and payroll releases move index futures as much as currency pairs. The only thing to check is the time zone the calendar is set to, because the release must be converted into the time zone of your bar data before you tag any bar.

References

  • Bailey, D. H., Borwein, J., López de Prado, M., & Zhu, Q. J. (2014). Pseudo-Mathematics and Financial Charlatanism: The Effects of Backtest Overfitting on Out-of-Sample Performance. Notices of the American Mathematical Society, 61(5), 458–471.
  • Harvey, C. R., & Liu, Y. (2015). Backtesting. The Journal of Portfolio Management, 42(1), 13–28.
  • White, H. (2000). A Reality Check for Data Snooping. Econometrica, 68(5), 1097–1126.