SPSS command: SPSS ACF

Autocorrelation and partial autocorrelation functions

The autocorrelation function (ACF) measures how strongly a series correlates with its own past at each lag; the partial autocorrelation function (PACF) removes the effect of the shorter lags in between.

Free · No account · Files stay on your device · Updated 18 October 2026

What it tells you

Crosstabs runs SPSS ACF and PACF with white-noise or Bartlett standard errors, the Box-Ljung test and optional log, regular and seasonal differencing.

  • Whether the series is white noise or has memory, from the Box-Ljung Q statistic at each lag.
  • Whether a trend calls for differencing: an ACF that decays very slowly is the classic sign.
  • Seasonality, as spikes at the seasonal lag (12 for monthly, 4 for quarterly data).
  • Candidate ARIMA orders: a PACF that cuts off after lag p suggests AR(p), an ACF that cuts off after lag q suggests MA(q).

When to use it

Use it when

  • Before fitting an ARIMA model, to choose differencing and the AR and MA orders.
  • To check whether period-to-period changes in a tracker are just noise or carry over from one wave to the next.
  • To test model residuals for remaining autocorrelation (ARIMA shows its own residual ACF).

Use something else when

  • You want the relationship between two different series: use cross-correlations.
  • You want to find cycles of unknown length: spectral analysis looks at all frequencies at once.
  • You have only a handful of periods: with fewer than about 20 points the correlations are too noisy to read reliably.

How to run it in Crosstabs

  1. 01

    Open Autocorrelations

    In Statistics mode, choose Autocorrelations (ACF) in the Forecasting group.

  2. 02

    Define the time axis

    Group respondent rows into periods or treat each row as a time point. The periodicity matters only for the seasonal difference.

  3. 03

    Choose the Series and Maximum lag

    Pick the Series and set Maximum lag (default 16, up to 60). Use at least two seasonal cycles of lags for seasonal data.

  4. 04

    Pick the Standard error method

    Independence (white noise) is the SPSS default; Bartlett's approximation (MA) widens the limits at higher lags when lower-lag autocorrelations are large.

  5. 05

    Transform and run

    Optionally tick Natural log transform and set Difference (0–2) and Seasonal difference (0–1). Keep Partial autocorrelations ticked for the PACF, then click Run.

Worked example

Computed by the Crosstabs engine from the synthetic data below when this page was built — not typed in.

Data

48 synthetic monthly values (January 2022 to December 2025) of a brand-tracker metric in percent: a level of 40 rising 0.25 points a month, a fixed seasonal pattern that peaks in December and dips in July, and normal noise (SD 1.1) from a fixed seed, so every build produces the same series.

Autocorrelations
LagAutocorrelationStd. ErrorBox-Ljung StatisticdfSig.
10.8090.14033.4171<.001
20.6420.13854.8952<.001
30.5020.13768.3483<.001
60.2230.13283.2236<.001
110.3650.124109.67011<.001
120.3740.122118.98112<.001

Selected lags of 12. Standard errors assume independence (white noise); no differencing.

Partial Autocorrelations
LagPartial AutocorrelationStd. Error
10.8090.144
2−0.0370.144
3−0.0180.144
6−0.0110.144
110.0830.144
120.0200.144

How to read it

The lag-1 autocorrelation is 0.809, far above its standard error of 0.140, and the Box-Ljung Q at lag 12 is 118.98 (p < .001), so the series is clearly not white noise. The slow decay from the trend and the swing between lag 6 (0.223) and lag 12 (0.374) point to differencing and a seasonal term before choosing ARIMA orders.

Output tables explained

Autocorrelations
Per lag: the autocorrelation, its standard error, the Box-Ljung statistic, df and significance. A significant Box-Ljung means the autocorrelations up to that lag are jointly non-zero.
Partial Autocorrelations
The PACF per lag with standard error 1/√n; values beyond about ±2 standard errors stand out.
ACF with 95% limits
Correlograms of the ACF and PACF with ±1.96 standard-error bands, using the chosen standard error method.

Assumptions and notes

  • The series is (or has been differenced to be) stationary; on a trending series the ACF mostly reflects the trend.
  • Time points are equally spaced; missing points use the Cryer formulas, with lag products over the available pairs.
  • The Box-Ljung test relies on an asymptotic chi-square approximation, which is rough for short series.

How the results are validated

On a 72-month seasonal series and an ARMA(1,1) series, autocorrelations and white-noise standard errors match statsmodels acf to 1e-12, Bartlett standard errors and Box-Ljung statistics (acorr_ljungbox) to 1e-10, p values to 1e-8 and the PACF (Levinson-Durbin) to 1e-10. With missing values, the Cryer-formula autocorrelations match both an independent numpy implementation and statsmodels to 1e-12, and the Box-Ljung statistics match the numpy implementation to 1e-10. Validation evidence

Questions

White-noise or Bartlett standard errors?

White-noise errors test each lag against pure noise and are the SPSS default. Bartlett's approximation assumes an MA process up to the previous lag, so it is the better guide when deciding where an ACF cuts off.

Should I difference before looking at the ACF?

If the ACF stays high for many lags, yes: set Difference to 1 and look again. For a seasonal pattern that persists, add a Seasonal difference of 1.

How many lags should I show?

The SPSS default of 16 suits non-seasonal data. For monthly data use at least 24 or 36 to see the seasonal lags; avoid lags beyond about a quarter of the series length.

Why is the Box-Ljung df blank at some lags?

When ACF is run on residuals of a fitted model, the df subtract the number of AR and MA parameters, so the first few lags have no valid test. On a raw series the df equal the lag.

Run Autocorrelations (ACF and PACF) on your own data

Open a .sav, CSV or Excel file. Everything runs in your browser; the file never leaves your device.

Open the workspace

SPSS is a trademark of IBM Corp. Crosstabs is not affiliated with or endorsed by IBM.