| xtpcaus | R Documentation |
Tests whether x Granger-causes y in a balanced panel using
either the Panel Fourier Toda-Yamamoto (PFTY) test or the Panel Quantile
Causality (PQC) test.
xtpcaus(
data,
y,
x,
panel_id,
time_id,
test = c("pfty", "pqc"),
pmax = 4L,
dmax = 1L,
nboot = 499L,
kmax = 3L,
ic = c("aic", "bic"),
quantiles = c(0.1, 0.25, 0.5, 0.75, 0.9),
seed = -1L
)
data |
A data frame in long format. |
y |
Character. Name of the dependent (caused) variable. |
x |
Character. Name of the independent (causing) variable. |
panel_id |
Character. Name of the panel identifier variable. |
time_id |
Character. Name of the time variable. |
test |
Character. Test type: |
pmax |
Integer. Maximum lag order for selection. Default is |
dmax |
Integer. Maximum integration order for Toda-Yamamoto
augmentation. Default is |
nboot |
Integer. Number of bootstrap replications. Minimum 99.
Default is |
kmax |
Integer. Maximum Fourier frequency (PFTY only). Default is
|
ic |
Character. Information criterion: |
quantiles |
Numeric vector. Quantile grid for PQC test (values strictly
between 0 and 1). Default is
|
seed |
Integer. Random seed for bootstrap. |
An object of class "xtpcaus" containing:
Character. "pfty" or "pqc".
Integer. Number of panel units.
Integer. Number of time periods.
Integer. Number of bootstrap replications.
Character. Name of the y variable.
Character. Name of the x variable.
For PFTY:
Numeric. Fisher panel statistic.
Integer. Degrees of freedom (2*N).
Numeric. Fisher p-value.
Numeric. Average individual Wald statistic.
Numeric. Dumitrescu-Hurlin Z-bar statistic.
Numeric. Z-bar p-value.
Numeric vector. Individual Wald statistics (length N).
Integer vector. Optimal Fourier frequencies (length N).
Numeric vector. Bootstrap p-values (length N).
Integer vector. Selected lag orders (length N).
For PQC:
Numeric vector. Quantiles tested.
Numeric vector. Wald statistics per quantile (x => y).
Numeric vector. Bootstrap p-values per quantile (x => y).
Numeric vector. Wald statistics per quantile (y => x).
Numeric vector. Bootstrap p-values per quantile (y => x).
Numeric. Sup-Wald statistic for x => y.
Numeric. Sup-Wald statistic for y => x.
Integer. Selected optimal lag.
Chuang, C.C., Kuan, C.M. and Lin, H.Y. (2009). Causality in quantiles and dynamic stock return-volume relations. Journal of Banking and Finance, 33(7), 1351–1360. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1016/j.jbankfin.2009.02.013")}
Emirmahmutoglu, F. and Kose, N. (2011). Testing for Granger causality in heterogeneous mixed panels. Economic Modelling, 28(3), 870–876. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1016/j.econmod.2010.10.018")}
Toda, H.Y. and Yamamoto, T. (1995). Statistical inference in vector autoregressions with possibly integrated processes. Journal of Econometrics, 66(1–2), 225–250. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1016/0304-4076(94)01616-8")}
Wang, K.M. and Nguyen, T.B. (2022). A quantile panel-type analysis of income inequality and healthcare expenditure. Economic Research, 35(1), 873–893. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1080/1331677X.2021.1952089")}
Yilanci, V. and Gorus, M.S. (2020). Does economic globalization have predictive power for ecological footprint. Environmental Science and Pollution Research, 27, 40552–40562. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1007/s11356-020-10092-9")}
dat <- grunfeld_panel()
# PFTY test (quick with few bootstrap reps)
res <- xtpcaus(dat, y = "invest", x = "mvalue",
panel_id = "firm", time_id = "year",
test = "pfty", pmax = 2L, dmax = 1L,
nboot = 99L, kmax = 2L, seed = 42L)
print(res)
# PQC test
res2 <- xtpcaus(dat, y = "invest", x = "mvalue",
panel_id = "firm", time_id = "year",
test = "pqc", pmax = 2L, nboot = 99L,
quantiles = c(0.25, 0.50, 0.75), seed = 42L)
print(res2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.