Non-stationarity and Differencing — A Simplification

Olabode James
3 min readApr 8, 2023

--

Image Generated by DALL-E-2 with Prompt — Time Series Stationarity

Non-stationarity in data cut across a lot of fields, not just Finance but inclusive will be primarily Climate monitoring, Macroeconomics, etc. The need to effectively model/forecast these types of data creates an interesting challenge due to the problem of non-stationarity. Non-stationarity means the data exhibit changes in mean, variance, or covariance over time, which like skewed data represents a very unique challenge to modelling. Thus, non-stationarity can be any or combination of the following major types -

  1. Trend non-stationary time series: These are time series that exhibit a systematic increase or decrease in the mean over time. For example, a time series of GDP over a period of several years may exhibit an upward trend due to economic growth.
  2. Seasonal non-stationary time series: These are time series that exhibit regular and repeating patterns over a fixed period of time. For example, sales of winter clothing may be higher during the winter months and lower during the summer months.
  3. Cyclical non-stationary time series: These are time series that exhibit repeated patterns that are not of a fixed period. These patterns can occur due to business cycles, economic cycles, or other long-term cycles in the data.
  4. Random walk non-stationary time series: These are time series where the difference between successive observations is a white noise process with a mean of zero and a constant variance. These types of series have no predictable patterns or trends and are often used to model stock prices or other financial data.
  5. Explosive non-stationary time series: These are time series that exhibit sudden and rapid changes in the mean, variance, or both. Examples of such time series include financial crises, natural disasters, or sudden changes in economic policies.

A technique for achieving stationarity is Differencing, and can be done in any of the classes above. With the need for differencing, there are two approaches — difference single time or difference multiple times vis-a-vis difference-stationarity time series and Integrated non-stationary processes.

Differencing is a transformation technique. It is used in time series analysis to transform a non-stationary time series into a stationary time series because stationary time series is easier to model due to the constant mean, variance, and covariance over time, and are easier to model and analyze using statistical methods.

To difference a time series, we subtract each observation from its previous observation to obtain a series of differences between consecutive observations. The silver bullet of Differencing is simply the removal of trends or patterns that cause the non-stationarity in the first place.

The contrast between the two types mentioned earlier is the order of differencing needed to achieve stationarity, difference-stationarity requires an n-order of differencing(or applies to multiple-order differenced series), while integrated non-stationary requires one order of differencing(or applies to first-order differenced series) to achieve time series modelling status(stationarity).

--

--

Olabode James
Olabode James

Written by Olabode James

Chief Solutions Architect, My joy is in solving problems ... everything else is eventual!

No responses yet