Correlogram should not be confused with Scatterplot.
In the analysis of data, a correlogram is a chart of correlation statistics. For example, in time series analysis, a plot of the sample autocorrelations
rh
h
The correlogram is a commonly used tool for checking randomness in a data set. If random, autocorrelations should be near zero for any and all time-lag separations. If non-random, then one or more of the autocorrelations will be significantly non-zero.
In addition, correlograms are used in the model identification stage for Box–Jenkins autoregressive moving average time series models. Autocorrelations should be near-zero for randomness; if the analyst does not check for randomness, then the validity of many of the statistical conclusions becomes suspect. The correlogram is an excellent way of checking for such randomness.
In multivariate analysis, correlation matrices shown as color-mapped images may also be called "correlograms" or "corrgrams".[1] [2] [3]
The correlogram can help provide answers to the following questions:[4]
Y=constant+error
valid and sufficient?
s\bar{Y
Randomness (along with fixed model, fixed variation, and fixed distribution) is one of the four assumptions that typically underlie all measurement processes. The randomness assumption is critically important for the following three reasons:
s\bar{Y
Y=constant+error
The autocorrelation coefficient at lag h is given by
rh=ch/c0
ch=
1 | |
N |
N-h | |
\sum | |
t=1 |
\left(Yt-\bar{Y}\right)\left(Yt+h-\bar{Y}\right)
c0=
1 | |
N |
N | |
\sum | |
t=1 |
\left(Yt-\bar{Y}\right)2
The resulting value of rh will range between −1 and +1.
Some sources may use the following formula for the autocovariance function:
ch=
1 | |
N-h |
N-h | |
\sum | |
t=1 |
\left(Yt-\bar{Y}\right)\left(Yt+h-\bar{Y}\right)
In contrast to the definition above, this definition allows us to compute
ch
Y1,...,YN
Yi\inRn
i=1,...,N
X=\begin{bmatrix}Y1-\barY& … &YN-\barY\end{bmatrix}\inRn
Q=X\topX
ch
h
Q
0
Q
N
c0
1
Q
N-1
c1
In the same graph one can draw upper and lower bounds for autocorrelation with significance level
\alpha
B=\pmz1-\alpha/2SE(rh)
rh
h
If the autocorrelation is higher (lower) than this upper (lower) bound, the null hypothesis that there is no autocorrelation at and beyond a given lag is rejected at a significance level of
\alpha
In the above, z1−α/2 is the quantile of the normal distribution; SE is the standard error, which can be computed by Bartlett's formula for MA(ℓ) processes:
SE(r | ||||
|
SE(r | |||||||||||||||||||
|
h>1.
In the example plotted, we can reject the null hypothesis that there is no autocorrelation between time-points which are separated by lags up to 4. For most longer periods one cannot reject the null hypothesis of no autocorrelation.
Note that there are two distinct formulas for generating the confidence bands:
1. If the correlogram is being used to test for randomness (i.e., there is no time dependence in the data), the following formula is recommended:
\pm
z1-\alpha/2 | |
\sqrt{N |
2. Correlograms are also used in the model identification stage for fitting ARIMA models. In this case, a moving average model is assumed for the data and the following confidence bands should be generated:
\pmz1-\alpha/2\sqrt{
1 | |
N |
k | |
\left(1+2\sum | |
i=1 |
2\right)} | |
r | |
i |
Correlograms are available in most general purpose statistical libraries.
Correlograms:
functions acf
and pacf
Corrgrams: