Error in PANEL STRUCTURAL VAR

Questions and discussions on Vector Autoregressions
polisci_nerd
Posts: 3
Joined: Mon Mar 29, 2021 6:13 am

Error in PANEL STRUCTURAL VAR

Unread post by polisci_nerd »

Hi,

I'm trying to estimate a panel structural var based on Pedroni, Peter (2013) "Structural Panel VARs", Econometrics, 1 (2),180-206. I got the code from Prof. Pedroni, and transformed my dataset (unbalanced panel) into the format the code required (balanced panel with NAs). However, when I try to estimate the model, I always get the following error.

processing panel member 1
chosenlag is 1
## MAT14. Non-invertible Matrix. Using Generalized Inverse for SYMMETRIC.
The Error Occurred At Location 968, Line 52 of loop/block

I don't know what went wrong. Could you please have a look at the data and code attached and help me if possible?
Attachments
panelSVAR-pedroni-econometrics-v25feb14.RPF
(21.46 KiB) Downloaded 811 times
DataPanel.xlsx
(57.56 KiB) Downloaded 761 times
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: Error in PANEL STRUCTURAL VAR

Unread post by TomDoan »

Individual 2 has only 10 usable data points. That's probably not enough to do the analysis that's required on each individual. (It estimates a separate 1 lag VAR on each individual.)
polisci_nerd
Posts: 3
Joined: Mon Mar 29, 2021 6:13 am

Re: Error in PANEL STRUCTURAL VAR

Unread post by polisci_nerd »

TomDoan wrote:Individual 2 has only 10 usable data points. That's probably not enough to do the analysis that's required on each individual. (It estimates a separate 1 lag VAR on each individual.)
Hi Tom,
Thanks for your reply. This makes sense. I actually already removed some short series before trying the svar. Do you have any recommendation about the minimum time periods of each individual for a panel svar? I have 4 endogenous variables, which means 5 parameters per equation, and 20 in total for the system. What is the safe minimum number of observations for running a panel var in my case?
polisci_nerd
Posts: 3
Joined: Mon Mar 29, 2021 6:13 am

Re: Error in PANEL STRUCTURAL VAR

Unread post by polisci_nerd »

TomDoan wrote:Individual 2 has only 10 usable data points. That's probably not enough to do the analysis that's required on each individual. (It estimates a separate 1 lag VAR on each individual.)
Hi Tom,
On a second thought, the short time series shouldn’t be the major reason for the error. VARs are estimated equation by equation, which means I never estimate more than 5 parameters in a single regression. So it should be feasible given the length of the shortest countries in my panel.
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: Error in PANEL STRUCTURAL VAR

Unread post by TomDoan »

Except that it runs the VAR on differences, so that loses one data point. Plus the one lag loses another, so you're down to 8 data points. Then it is freely estimating a 4 x 4 covariance matrix, which, in effect, means three extra free coefficients (for the contemporaneous cross effects). All told, that means with 10 data points and 4 variables, you're getting a perfect fit. With 11 data points, you wouldn't have a perfect fit, but the results would be quite suspect due to overfitting. I probably would want closer to 20 data points per individual to be safe.
Post Reply