Time Series Interpolation and Frequency Conversion

The EXPAND procedure provides time interval conversion and missing value interpolation for time series. The EXPAND procedure includes the following features:

  • conversion of time series frequency; for example, constructing quarterly estimates from annual series or aggregating quarterly values to annual values

  • conversion of irregular observations to periodic observations

  • interpolation of missing values in time series

  • conversion of observation types; for example, estimate stocks from flows and vice versa. All possible conversions are supported between any of the following:

    • beginning of period

    • end of period

    • period midpoint

    • period total

    • period average

  • conversion of time series phase shift; for example, conversion between fiscal years and calendar years

  • identifying observations including the following:

    • identification of the time interval of the input values

    • validation of the input data set observations

    • computation of the ID values for the observations in the output data set

  • choice of four interpolation methods:

    • cubic splines

    • linear splines

    • step functions

    • simple aggregation

  • ability to perform extrapolation by a linear projection of the trend of the cubic spline curve fit to the input data

  • ability to transform series before and after interpolation (or without interpolation) by using any of the following:

    • constant shift or scale

    • sign change or absolute value

    • logarithm, exponential, square root, square, logistic, inverse logistic

    • lags, leads, differences

    • classical decomposition

    • bounds, trims, reverse series

    • centered moving, cumulative, or backward moving average

    • centered moving, cumulative, or backward moving range

    • centered moving, cumulative, or backward moving geometric mean

    • centered moving, cumulative, or backward moving maximum

    • centered moving, cumulative, or backward moving median

    • centered moving, cumulative, or backward moving minimum

    • centered moving, cumulative, or backward moving product

    • centered moving, cumulative, or backward moving corrected sum of squares

    • centered moving, cumulative, or backward moving uncorrected sum of squares

    • centered moving, cumulative, or backward moving rank

    • centered moving, cumulative, or backward moving standard deviation

    • centered moving, cumulative, or backward moving sum

    • centered moving, cumulative, or backward moving median

    • centered moving, cumulative, or backward moving t-value

    • centered moving, cumulative, or backward moving variance

  • support for a wide range of time series frequencies:

    • YEAR

    • SEMIYEAR

    • QUARTER

    • MONTH

    • SEMIMONTH

    • TENDAY

    • WEEK

    • WEEKDAY

    • DAY

    • HOUR

    • MINUTE

    • SECOND

  • support for repeating of shifting the basic interval types to define a great variety of different frequencies, such as fiscal years, biennial periods, work shifts, and so forth

Refer to Chapter 3, Working with Time Series Data, and Chapter 4, Date Intervals, Formats, and Functions, for more information about time series data transformations.