Fractional Differentiation
A way to make a price series stationary while keeping most of its memory, by differencing it a fractional amount instead of the usual whole step that returns represent.
Prerequisites: Stationarity, Unit Roots and the ADF Test
Modeling prices runs into a dilemma. Raw price levels are non-stationary, they trend and wander, so most statistical and machine-learning models choke on them (see Stationarity and Unit Roots and the ADF Test). The usual fix is to take returns, that is, to difference the series once. But a full difference is a sledgehammer: it makes the series stationary and erases almost all of its memory. Today's return tells you nothing about whether the price is high or low, near a support level, or far from its recent range. You threw away the very "level" information a predictor might want.
Fractional differentiation is the scalpel. Instead of differencing a whole step (order , which gives returns) or not at all (order , the raw level), you difference by a fractional order between and , just enough to pass a stationarity test while keeping as much memory as possible.
The fractional difference operator
Differencing is the operator , where is the backshift (lag) operator: . A first difference is . Raising it to a real power and expanding the binomial series gives an infinite weighted sum of past values:
In words: the fractionally-differenced value at time is a weighted sum of the current and all past prices, with weights that you build by a simple recursion starting from . The key is how fast those weights decay. For they collapse to , ordinary returns, no memory beyond one lag. For they are , the untouched level. For a fraction like , the weights decay slowly, so the series keeps a long, fading memory of the past.
| Lag | (level) | (return) | |
|---|---|---|---|
| 0 | 1 | 1 | 1 |
| 1 | 0 | −0.500 | −1 |
| 2 | 0 | −0.125 | 0 |
| 3 | 0 | −0.063 | 0 |
| 4 | 0 | −0.039 | 0 |
| 5 | 0 | −0.027 | 0 |
Weights on past prices for three differencing orders. Returns () keep only lag 0 and 1, wiping out all longer memory. The fractional order keeps a slowly-decaying tail, so the transformed series still remembers where the price has been.
Full differencing (returns) makes a price series stationary but throws away its memory. Fractional differencing removes only enough trend to pass a stationarity test while retaining a long, decaying memory of past levels, the best of both worlds for a feature.
The stationarity-vs-memory trade-off
As you raise from toward , two things move in opposite directions. Stationarity improves, the ADF test statistic gets more negative and eventually rejects the unit root. Memory fades, the correlation between the transformed series and the original price level drops toward zero. The sweet spot is the smallest that passes the stationarity test: you buy just enough stationarity and pay the minimum possible in lost memory.
Worked example
You have a log-price series that fails the ADF test badly (it has a unit root). Two extremes:
- Returns (). The ADF test strongly rejects the unit root, fully stationary, but the correlation between returns and the price level is essentially . Every trace of "how high is the price" is gone.
- Level (). Correlation with the original is (it is the original), but it's hopelessly non-stationary.
Now sweep upward and re-run ADF at each step. Suppose the series first passes the ADF test at the level around . At that , the transformed series still has a correlation of roughly with the original price level, it is now stationary yet has kept almost all of its memory. Compare that to returns, which are stationary but retain none. Feed the series to your model and it gets both a well-behaved input and the level information; feed it returns and it only gets the latter erased. That preserved memory is often exactly what carries the predictive signal.
Don't guess . Sweep it from upward in small steps, run the ADF test at each, and pick the smallest that just clears your significance threshold. Going higher only sacrifices memory you didn't need to sacrifice.
Pitfalls
- Truncating the weights too early. The weight tail decays slowly, so a short window drops real memory. Use a small weight-threshold cutoff, not an arbitrary fixed window.
- Look-ahead through the window. The weighted sum uses past values only, but make sure your implementation never reaches forward, and fit any scaler after differencing, inside each CV fold.
- Over-differencing. Picking a large "to be safe" needlessly destroys memory, the opposite of the goal. Smallest passing wins.
- Assuming it creates signal. Fractional differencing is a preprocessing step that preserves information; it doesn't manufacture predictability where none exists.
Returns are the default in finance precisely because they're stationary, but that convenience is a hidden cost: they discard the price level, which often carries the signal. Reflexively differencing to order can be quietly throwing away the most useful part of your data.
In interviews
If asked "how do you make a price series stationary without losing its memory?", name fractional differentiation: difference by a real order between and , chosen as the smallest value that passes the ADF test, so the weights on past prices decay slowly and retain memory. Contrast it with returns (, stationary but memoryless) and levels (, full memory but non-stationary), and mention that it's a feature-engineering step feeding the model's inputs, not a source of alpha by itself.
Related concepts
Practice in interviews
Further reading
- López de Prado, Advances in Financial Machine Learning (Ch. 5)
- Hosking, Fractional Differencing