Cointegration and Error Correction Model: Analyzing Variables That Move Together
1. Cointegration and Error Correction Model
Most macroeconomic time series variables such as GDP, consumption, and prices show a common trend of increasing or decreasing together over time. However, when these non-stationary series variables are used directly in regression analysis, it's easy to fall into the problem of 'spurious regression' where variables appear statistically significant even though there's actually no causal relationship.
So how should we analyze these variables? The answer can be found in Cointegration, which examines whether variables maintain a stable 'equilibrium relationship' and move together in the long run. For example, an individual's income and consumption may be inconsistent in the short term, but in the long term, they don't deviate far from each other.
Now let's assume we've confirmed that two variables are in such a cointegrating relationship. Then how are short-term imbalances adjusted in the future?
The Error Correction Model (ECM) answers precisely this question. ECM clearly analyzes the short-term dynamics of how fast variables 'correct' the 'error' and return to equilibrium when they temporarily deviate from long-run equilibrium.
1-1. Core Idea
Variables that are individually non-stationary can have a stable equilibrium relationship in the long run, that is, a cointegration relationship. The Engle-Granger method first estimates this long-run equilibrium relationship, then measures the 'error (residual)' of deviation from that relationship, and models the short-term adjustment process of this error returning to equilibrium.
1-2. Analysis
Let's specifically see how to confirm a cointegration relationship and apply the error correction model.
Stage 1: Estimate Long-Run Equilibrium Relationship and Calculate Residuals
First, run OLS regression of variable on to estimate the long-run equilibrium relationship.
Calculate the residual obtained here. This residual represents precisely the 'degree of deviation from long-run equilibrium (error)'.
Stage 2: Cointegration Test Using Residuals and ECM Construction
Now using the 'error' obtained in stage 1, proceed with two important analyses.
Stage 2-1: Cointegration Test
If the two variables are truly in a cointegrating relationship, the error deviating from long-run equilibrium () should be a stationary series that doesn't diverge forever but eventually returns to the mean (0). Therefore, perform a Unit Root Test (e.g., ADF test) on this residual .
- Null hypothesis (): A unit root exists in the residual. (The residual is non-stationary) No cointegration relationship.
- Alternative hypothesis (): No unit root in the residual. (The residual is stationary) A cointegration relationship exists.
If the null hypothesis is rejected here, we can conclude that a long-run equilibrium relationship exists between the two variables.
Stage 2-2: Error Correction Model (ECM) Construction
If the two variables are in a cointegrating relationship, short-term changes () can be modeled as showing movements to 'correct' past errors that deviated from long-run equilibrium. At this time, the past value of the residual obtained in stage 1 () is included in the regression as an 'error correction term'.
- : First difference values of each variable, meaning short-term changes.
- : Error Correction Term. That is, it represents the magnitude of imbalance at the previous time point .
- : Speed of adjustment. This coefficient usually has a negative value. For example, if , it means 20% of the past imbalance is adjusted toward equilibrium at the current time point.
2. Extension to Multivariate: Vector Error Correction Model (VECM)
While the Error Correction Model (ECM) mainly deals with the relationship between two variables, VECM is a model that extends this to a system with three or more variables.
2-1. Core Idea
VECM is like a situation where several dogs are tied together on leashes and walking together.
- Each dog (individual time series variable): Each variable such as GDP, consumption, investment can move freely in the short term.
- Leashes (long-run equilibrium relationship / cointegration): However, there are long-run equilibrium relationships (cointegration) that bind variables to each other, so they can't deviate too far from each other.
- Error Correction: If one dog gets too far ahead (error occurs), the leash tightens and slows down, or other dogs catch up (error is corrected) to maintain an appropriate distance again.
Thus, VECM is a powerful analytical tool that comprehensively explains how multiple variables in a cointegrating relationship, while influencing each other's changes in the short term, maintain stable equilibrium in the long term.
2-2. Mathematical Structure of VECM
VECM is a transformed form of the Vector Autoregression (VAR) model for non-stationary time series vector as follows.
- : Represents the effect of short-term changes at past time points on current short-term changes ().
- : The error correction term, which is the core of the model. It contains the effect that how much the level at past time point () deviated from long-run equilibrium affects current changes.
This matrix can be decomposed into the product of two matrices, .
- : Cointegrating vector, which defines the long-run equilibrium relationship among variables. is precisely the term representing the past imbalance (error).
- : Adjustment coefficient vector, which represents the adjustment speed of each variable returning to equilibrium when an error occurs deviating from long-run equilibrium.
2-3. How to Confirm Cointegration Relationship? - Johansen Test
To use VECM, we must first confirm whether there is a cointegrating relationship among variables, and if so, how many. In systems with 3 or more variables, using the Johansen Test is the standard method.
The Johansen test statistically tests the number of independent long-run equilibrium relationships () existing in the system by analyzing the rank of the matrix. If this test rejects the null hypothesis that the number of cointegrating relationships is 0, we secure the basis for using VECM.
3. Examining the Operating Principle of VECM in Detail
As mentioned earlier, VECM is expressed as the following matrix equation transforming VAR (Vector Autoregression model).
This matrix equation is actually a system that expresses multiple regression equations at once. Let's unpack this equation through a specific example where 3 variables (GDP, consumption C, investment I) are in a cointegrating relationship.
3-1. Definition of Vectors
First, the vector used in VECM is a column vector consisting of variables included in the system.
3-2 Dissecting the Error Correction Term
The core of VECM is the error correction term that corrects errors deviating from long-run equilibrium. This term is decomposed as .
① Long-run equilibrium relationship and error
- The cointegrating vector defines the long-run equilibrium relationship among variables. For example, if there is one long-run equilibrium relationship in the system, is as follows. (Normalize the first variable to 1)
- Multiplying this vector by past variable calculates a single value representing the 'error' deviating from long-run equilibrium.
Here is precisely the imbalance at past time point ().
② Adjustment speed
- The adjustment coefficient vector represents how quickly each variable reacts to this imbalance and returns to equilibrium.
3-3. Complete VECM Regression Equation System
Now combining the above elements, the VECM matrix equation actually means the following system of 3 regression equations. (Only 1 lag is shown for simplification)
[Equation 1: Regression for ]
[Equation 2: Regression for ]
[Equation 3: Regression for ]
When viewed this way, it becomes clear that VECM is a sophisticated model explaining the short-term change of each variable () as (1) response to past imbalance () and (2) response to past short-term changes of other variables ().
In actual analysis, statistical packages estimate this complex system at once through the Johansen procedure, etc., to find and values.
4. Integrated Analysis Encompassing Long-Run Equilibrium and Short-Run Adjustment
Cointegration and error correction models go beyond simply being technical techniques to solve the spurious regression problem of non-stationary time series data. This methodology gives mathematical rigor to the powerful economic intuition that 'variables find stable equilibrium in the long run'.
Through this framework, we can catch meaningful long-run equilibrium relationships () even in a sea of non-stationary data. Furthermore, ECM and VECM dynamically depict at what speed () and through what interactions economic agents return to equilibrium when they deviate from it in response to short-term shocks.
Ultimately, these models are powerful narrative tools that unravel the long-term directionality and short-term volatility of complexly intertwined macroeconomic systems into one integrated story.
Source: My own Lecture Notes from Graduate School - Macroeconometrics