Convergence and Dynamic Factor Models
Select optimal VAR lag order with multiple criteria
convergenceDFM: Dynamic Factor Models for Economic Convergence Analysi...
Incremental R-squared from X in OU model
Diagnose and prepare data matrices
Estimate Dynamic Factor Model with VAR dynamics
Estimate Factor Ornstein-Uhlenbeck model (Stan if available)
Extract X innovations from VAR model
Plot error correction panel
Read CPI data from Excel file
Rescue short-run channel test
Rotation null hypothesis test for factor coupling
Normalize matrix rows to sum to one
Complete factor-OU convergence analysis pipeline
Run comprehensive robustness test suite
Run rotation null test on complete analysis results
Select optimal number of PLS components with cross-validation
Classical cointegration control (Johansen trace or eigen)
Jackknife robustness test by sector
Permutation-based robustness test
Reweighting-based robustness test
Convert European number format to numeric
Simple factor dynamics visualization
Visualize factor dynamics comprehensively
Tests convergence in macro-financial panels combining Dynamic Factor Models (DFM) and mean-reverting Ornstein-Uhlenbeck (OU) processes. Provides: (i) static/approximate DFMs for large panels with VAR/VECM stability checks, Portmanteau tests and rolling out-of-sample R^2, following Stock and Watson (2002) <doi:10.1198/073500102317351921> and the Generalized Dynamic Factor Model of Forni, Hallin, Lippi and Reichlin (2000) <doi:10.1162/003465300559037>; (ii) cointegration analysis à la Johansen (1988) <doi:10.1016/0165-1889(88)90041-3>; (iii) OU-based convergence and half-life summaries grounded in Uhlenbeck and Ornstein (1930) <doi:10.1103/PhysRev.36.823> and Vasicek (1977) <doi:10.1016/0304-405X(77)90016-2>; (iv) robust inference via 'sandwich' HC/HAC estimators (Zeileis (2004) <doi:10.18637/jss.v011.i10>) and regression diagnostics ('lmtest'); and (v) optional PLS-based factor preselection (Mevik and Wehrens (2007) <doi:10.18637/jss.v018.i02>). Functions emphasize reproducibility and clear, publication-ready summaries.