Macroeconomics Forecasting

macroeconomic forecasting and policy scenario analysis

 

Macroeconomecs

Behavioral relationshics

Econometrics

Software

 

  • Properties of Time Series Data and Model Design
  • Dynamic Specification and the Use of Vector Autoregression (VAR) and Error Correction Models (VECMs)
  •  Evaluation of Macroeconometric Models
  •  Forecast Uncertainty and Forecasting for Policy Analysis 

 

hands-on demonstrations of model-building, forecasting and policy analysis

 

The fallowing content is focuses on the main points in practice. Here I go just direct to what to do and show some visual examples from the IMF source.

Is assumed a base knowledge of time series (econometrics) theory. I don't provide a big explanation of the concepts, only I show up the illustration or some key considerations. 

 

Model Strategies:
- Develop your model base on the properties of the data.
- Long Run or Short Run
- Linearity or non linearity
- MSE threshold: bias vs variance

 


[WORK IN PROGRESS]

PENDIENTE AGREGAR R CODE IN PRACTICES

Time Series Analysis

This is the firts step, and will be: 

  • Univariate Analysis
  • Multivariate analysis

Science and Art:

  • Understanding the behavior
    • pdf of y_t (mean and variance) 
  • Assesing/testing

Class of process:

  • Stationary vs nonstationry
  • Covariance stationary or depend on time

 

 Nonstationary Processes

  • Characterize the serie
  • Test 
Mean dynamic (ARMA)
Volatility dynamic 
 

General Process (ARMA–GARCH, univariate)

Repeat and practice this process until it look normal.


Revisar estacionariedad 
  • Aplicar prueba Dickey-Fuller (ADF). 
  • Determinar si la serie es estacionaria o no. 
  • Si no lo es → diferenciar la serie hasta que lo sea. 

Trabajar con la serie estacionaria
 
Analizar autocorrelación en niveles 
  • Revisar ACF y PACF. 
  • Si NO hay autocorrelación → la serie es ruido blanco (no requiere modelo). 
  • Si SÍ hay autocorrelación → estimar un modelo ARMA. 

 Analizar autocorrelación en la serie al cuadrado 
  • Evaluar si hay patrones en la volatilidad. 
  • Si NO hay autocorrelación → varianza constante. 
  • Si SÍ hay autocorrelación → hay efecto ARCH → considerar modelo GARCH. 

Elegir el modelo según resultados 
  •  Sin autocorrelación en niveles ni en cuadrados → Ruido blanco 
  •  Autocorrelación en niveles, pero no en cuadrados → ARMA 
  • Sin autocorrelación en niveles, pero sí en cuadrados → GARCH 
  • Autocorrelación en niveles y en cuadrados → ARMA-GARCH 

Validar el modelo 
  • Revisar que los residuos no tengan autocorrelación. 
  • Revisar que no quede efecto ARCH. 
  • Confirmar que el modelo es estable y útil para pronóstico.  
  •  

 

Identification:

  1. Visual inspection 
  2.  Learned about possible processes for y
  3. Identification
    1. Autocovariance (ACF or Correlogram)
    2. Autocorrelation (ACF or Correlogram)
    3. Partial Autocorrelation 

 

 

 

 

 

 

 

    4. Summarize the basic patterns 

 

 

Modeling 

        4.1. Some considerations:

  •  Possible aproach: begin with parsinomious low order AR, check residuals to decide on possible MA terms.
  • ACF's that do not go to zero could be sign of nonstationarity
  •  ACF of both AR, ARMA decay gradually, drops to 0 for MA
  • PACF decay gradually for ARMA, MA; drop to 0 for AR 

    5. Estimate several alternatives

 

de-trending procedures:

  • first differencing 
  • and time-trend regression

 First differencing is appropriate for I(1) time series and time-trend regression is appropriate for trend stationary I(0) time series.

 

Unit root tests can be used to determine what to do. 

 

Random Walk

Random walk with drift 

 

 

Estimation

Choose best model, based on:

  • Significance of coeficients
  • Fit vs parsimony
  • Akaike Information Criterion (AIC):        AIC = TAIC = T ln(SSR) + 2(p+ q+ 1) )
  • Schwartz Bayesian Criterion (SBC):        SBC = Tln(SSR)+ (p + q+ 1)ln(T)
  • White noise residuals 
  • Ability to forecast**
    • How well the model forecast "out of sample"
    • Compute  the "forecast errors":
      • Mean Squared Prediction Error
      • Granger-Newbold Test
      • Diebold-Mariano Test 
  • Account for possible structural breaks **
    • Does the model apply equally well to the entire sample, or do parameter change (significantly) within the sample.
      • Chow test
      • is not strong recursive estimation 

 

Key concepts: 

Unit Root Test

- DF and ADF 

 

Auto Correlation Function (ACF) 

  

Implementation

 
 
 

Econometrics & Time Series  - Key Notions

1. Forecast Evaluation
Key metrics: MSFE, MAE, RMSE. Always evaluate out-of-sample.
Best practice: combine forecasts to reduce variance and model risk.
Rule: Average + dispersion of forecast errors → full evaluation.
 
2. ACF / PACF Identification
AR(p): PACF cuts off at p, ACF decays.
MA(q): ACF cuts off at q, PACF decays.
ARMA: both decay.
 
3. Stationarity & Unit Roots
ADF: adds lags to remove serial correlation.
PP: robust correction (Newey-West).
KPSS: tests stationarity (complementary).
Decision: if fail to reject unit root → difference data.
 
4. Spurious Regression
Occurs when variables are I(1) and NOT cointegrated.
Leads to high R2 and false significance.
Solution: test cointegration or difference data.
 
5. Cointegration & VECM
If 0 < r < n → cointegration exists.
Use VECM: includes error correction term.
ECT captures long-run equilibrium adjustment.
 
6. VAR vs VECM
VAR (levels): stationary variables.
VAR (differences): no cointegration.
VECM: cointegrated variables.
Ignoring ECT → misspecification.
 
7. SVAR
Used for structural shock analysis.
Main tools: Impulse Response Functions (IRF), FEVD.
Focus: causal interpretation, not just forecasting.
 
8. Heteroskedasticity (ARCH/GARCH)
OLS coefficients unbiased, but standard errors incorrect.
ARCH effects → time-varying volatility.
Solution: GARCH or robust standard errors.
 
9. Residual Diagnostics
Check: normality, autocorrelation, heteroskedasticity.
Tests: Jarque-Bera, Breusch-Godfrey, ARCH-LM.
 
10. Forecast Combination
Equal weights often perform very well.
Inverse MSFE weights use past performance.
Avoid complex weighting with small samples.
 
11. Weak Exogeneity
Test: is adjustment coefficient = 0?
If yes → variable does not adjust to equilibrium.
Important for causal interpretation.
 
12. ECM Interpretation
Error Correction Term coefficient should be:
- Negative
- Significant
Ensures convergence to equilibrium.
 
Quick Decision Tree
1. Test stationarity (ADF/PP)
2. If non-stationary → test cointegration (Johansen)
3. If cointegrated → VECM
4. If not → VAR in differences
5. Always validate with diagnostics + forecast evaluation
 

Condensed Process:

ADF: test unit root. If fail to reject → difference data.
VAR: use if stationary. VECM: use if cointegrated.
ACF/PACF: AR → PACF cutoff; MA → ACF cutoff.
Spurious regression: I(1) + no cointegration.
Forecast: evaluate out-of-sample using MSFE.
Combine forecasts for robustness.
ARCH: heteroskedasticity → wrong SE, not coefficients.
Weak exogeneity: α = 0 (no adjustment).
ECT: should be negative and significant.

 

 

 

Model Identification and Diagnostic 

  • Plot the residual and identified is there is problem in period with specific shocks (recessions, covid-19, etc...) add a dummy with this period. 

 Forecasting

  • Within-sample: uses a subset of the observed sample to generate forecasts for periods that remain within the full sample range, excluding the selected estimation subsample.
  • Out-of-sample: uses all available sample information to generate forecasts for periods beyond the observed sample range.

REFERENCES

James Stock and Marc Watson, “Introduction to Econometrics”, 3rd Edition.
Jeffrey Wooldridge, “Introductory Econometrics: A Modern Approach”.
Arthur S. Goldberger, “Introductory Econometrics”.
 

ECONOMETRIC THEORY AND APPLIED TIME SERIES
Walter Enders, “Applied Econometric Time Series”, 3rd Edition.
James Hamilton, “Time Series Analysis”.
Helmut Lütkepohl , “New Introduction to Multiple Time Series Analysis”.
Arthur S. Goldberger , “A Course in Econometrics”
Jack Johnston and John Dinardo, “Econometric Methods”.
S. Ouliaris, A.R. Pagan and J. Restrepo, “Quantitative Macroeconomic
Modeling with Structural Vector Autoregressions – An EViews
Implementation”.
 

FORECASTING
Frank Diebold, “Elements of Forecasting”, 4t 

Entradas populares

SQL

Lo mas consultado

SQL

Entradas populares

SQL