pvargmm: GMM Estimation of Panel VAR Models

View source: R/pvar.R

pvargmmR Documentation

GMM Estimation of Panel VAR Models

Description

Estimates a panel vector autoregressive (PVAR) model with fixed effects.

Usage

pvargmm(
  dependent_vars,
  lags,
  predet_vars,
  exog_vars,
  transformation = "fd",
  data,
  panel_identifier = c(1, 2),
  steps,
  system_instruments = FALSE,
  system_constant = TRUE,
  pca_instruments = FALSE,
  pca_eigenvalue = 1,
  max_instr_dependent_vars,
  max_instr_predet_vars,
  min_instr_dependent_vars = 2L,
  min_instr_predet_vars = 1L,
  collapse = FALSE,
  tol = 1e-09,
  progressbar = TRUE
)

Arguments

dependent_vars

Dependent variables

lags

Number of lags of dependent variables

predet_vars

Predetermined variables

exog_vars

Exogenous variables

transformation

First-difference "fd" or forward orthogonal deviations "fod"

data

Data set

panel_identifier

Vector of panel identifiers

steps

"onestep", "twostep" or "mstep" estimation

system_instruments

System GMM estimator

system_constant

Constant only available with the System GMM estimator in each equation

pca_instruments

Apply PCA to instruments matrix

pca_eigenvalue

Cut-off eigenvalue for PCA analysis

max_instr_dependent_vars

Maximum number of instruments for dependent variables

max_instr_predet_vars

Maximum number of instruments for predetermined variables

min_instr_dependent_vars

Minimum number of instruments for dependent variables

min_instr_predet_vars

Minimum number of instruments for predetermined variables

collapse

Use collapse option

tol

relative tolerance to detect zero singular values in "ginv"

progressbar

show progress bar

Details

The first vector autoregressive panel model (PVAR) was introduced by Holtz-Eakin et al. (1988). Binder et al. (2005) extend their equation-by-equation estimator for a PVAR model with only endogenous variables that are lagged by one period. We further improve this model in Sigmund and Ferstl (2021) to allow for p lags of m endogenous variables, k predetermined variables and n strictly exogenous variables.

Therefore, we consider the following stationary PVAR with fixed effects.

yi,t = μi + ∑l=1pAlyi,t-l + Bxi,t + Csi,t + εi,t

Let yi,t ∈ ℜm be an m×1 vector of endogenous variables for the ith cross-sectional unit at time t. Let yi,t-l ∈ ℜm be an m×1 vector of lagged endogenous variables. Let xi,t ∈ ℜk be an k×1 vector of predetermined variables that are potentially correlated with past errors. Let si,t ∈ ℜn be an n×1 vector of strictly exogenous variables that neither depend on εi,t nor on εi,t-s for s = 1,…,T. The idiosyncratic error vector εi,t ∈ ℜm is assumed to be well-behaved and independent from both the regressors xi,t and si,t and the individual error component μi. Stationarity requires that all unit roots of the PVAR model fall inside the unit circle, which therefore places some constraints on the fixed effect μi. The cross section i and the time section t are defined as follows: i = 1,…,N and t = 1,…T. In this specification we assume parameter homogeneity for Al (m×m), B (m×k) and C (m×n) for all i.

A PVAR model is hence a combination of a single equation dynamic panel model (DPM) and a vector autoregressive model (VAR).

First difference and system GMM estimators for single equation dynamic panel data models have been implemented in the STATA package xtabond2 by Roodman (2009) and some of the features are also available in the R package plm.

For more technical details on the estimation, please refer to our paper Sigmund and Ferstl (2021).

There we define the first difference moment conditions (see Holtz-Eakin et al., 1988; Arellano and Bond, 1991), formalize the ideas to reduce the number of moment conditions by linear transformations of the instrument matrix and define the one- and two-step GMM estimator. Furthermore, we setup the system moment conditions as defined in Blundell and Bond (1998) and present the extended GMM estimator. In addition to the GMM-estimators we contribute to the literature by providing specification tests (Hansen overidentification test, lag selection criterion and stability test of the PVAR polynomial) and classical structural analysis for PVAR models such as orthogonal and generalized impulse response functions, bootstrapped confidence intervals for impulse response analysis and forecast error variance decompositions. Finally, we implement the first difference and the forward orthogonal transformation to remove the fixed effects.

Value

A pvargmm object containing the estimation results.

References

Arellano, M., Bond, S. (1991) Some Tests of Specification for Panel Sata: Monte Carlo Evidence and an Application to Employment Equations The Review of Economic Studies, 58(2), 277–297, doi: 10.2307/2297968

Binder M., Hsiao C., Pesaran M.H. (2005) Estimation and Inference in Short Panel Vector Autoregressions with Unit Roots and Cointegration Econometric Theory, 21(4), 795–837, doi: 10.1017/S0266466605050413

Blundell R., Bond S. (1998). Initial Conditions and Moment Restrictions in Dynamic Panel Data Models Journal of Econometrics, 87(1), 115–143, doi: 10.1016/S0304-4076(98)00009-8

Holtz-Eakin D., Newey W., Rosen H.S. (1988) Estimating Vector Autoregressions with Panel Data, Econometrica, 56(6), 1371–1395, doi: 10.2307/1913103

Roodman, D. (2009) How to Do xtabond2: An Introduction to Difference and System GMM in Stata The Stata Journal, 9(1), 86–136, https://www.stata-journal.com/article.html?article=st0159

Sigmund, M., Ferstl, R. (2021) Panel Vector Autoregression in R with the Package panelvar The Quarterly Review of Economics and Finance doi: 10.1016/j.qref.2019.01.001

See Also

stability for stability tests

oirf and girf for orthogonal and generalized impulse response functions (including bootstrapped confidence intervals)

coef.pvargmm, se, pvalue, fixedeffects for extrator functions for the most important results

fevd_orthogonal for forecast error variance decomposition

Examples

## Not run: 
library(panelvar)
data(abdata)
ex3_abdata <-pvargmm(
 dependent_vars = c("emp"),
 lags = 4,
 predet_vars = c("wage"),
 exog_vars = c("cap"),
 transformation = "fd",
 data = abdata,
 panel_identifier = c("id", "year"),
 steps = c("twostep"),
 system_instruments = TRUE,
 max_instr_dependent_vars = 99,
 max_instr_predet_vars = 99,
 min_instr_dependent_vars = 2L,
 min_instr_predet_vars = 1L,
 collapse = FALSE
)

## End(Not run)
data("ex3_abdata")
summary(ex3_abdata)

data("Dahlberg")
## Not run: 
ex1_dahlberg_data <- pvargmm(dependent_vars = c("expenditures", "revenues", "grants"),
                             lags = 1,
                             transformation = "fod",
                             data = Dahlberg,
                             panel_identifier=c("id", "year"),
                             steps = c("twostep"),
                             system_instruments = FALSE,
                             max_instr_dependent_vars = 99,
                             max_instr_predet_vars = 99,
                             min_instr_dependent_vars = 2L,
                             min_instr_predet_vars = 1L,
                             collapse = FALSE
)

## End(Not run)
data("ex1_dahlberg_data")
summary(ex1_dahlberg_data)

panelvar documentation built on Jan. 6, 2023, 1:17 a.m.

Related to pvargmm in panelvar...