I have a timeseries I am looking to transform with fractional differences per the following description:

enter image description here

The idea being to retain the essence of stationarity of, say, a log transformed integer series while preserving some of the 'memory' present in the levels of the values in the original series.

I can code this up manually but wondering what the more direct route might be within WL / Mathematica -- preferably via 'first class' functions within the language. Any advice greatly appreciated!


For sake of a reproducible and fun example for the community, let's assume I want the fractional differences of a financial timeseries object

levels = QuantityMagnitude@FinancialData["SPY",{2020,1,1}]

The stationary transform is trivial:

logTransform = Differences@Log@levels

How would I obtain the fractional differences of levels rather than the simple log transform? Assume a d value of .4


This github repo https://github.com/simaki/fracdiff nails the implementation in Python where the following plot is produced:

enter image description here

Underlying source here: https://github.com/simaki/fracdiff/blob/main/fracdiff/fracdiff.py

Really just trying to figure out what the first-class implementation of this in WL would use!

  • $\begingroup$ Try: Series[(1 - b)^d, {b, 0, 5}] $\endgroup$ Mar 16, 2021 at 11:13
  • $\begingroup$ Thanks for this. I've added a little contextual example to the question. If you can apply your comment to a full answer for this additional context, I will gladly award you the answer! $\endgroup$
    – R110
    Mar 16, 2021 at 11:58

1 Answer 1


Try the following:

Series[(1 - b)^d, {b, 0, 5}]

enter image description here

  • $\begingroup$ I'd very interested as well for answer to this question. $\endgroup$ Apr 10 at 21:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.