dimanche 14 avril 2019

How do I perform a joint Wald test on panel data regression coefficients against some specific values?

I would like to do a simple joint Wald test on my fixed-effects regression coefficients but I want to set the restriction to something other than zero. More specifically I would like to test: H0: ai=0 and b=1 for every i or basically, whether the extracted intercepts from fixed effects model (ai) (I know there is no intercept in fixed-effects model but you can still extract them through fixef() command and they should be close to zero if fixed-effects model is the correct model) is equal to zero for each i and my coefficients (bi) are equal to 1.

Here is what I have:

library(plm)


form <- R_excess ~ I(beta_MKT_RF*MKT_RF) + I(beta_HML*HML) + I(beta_SMB*SMB)
reg1 <- plm(form, data=nlspd, model="within")

summary(reg1, vcov =function(x) vcovSCC(x, type="HC3", maxlag=12))


And here is the output as you can see my coefficients are all close to 1:

Call:
plm(formula = form, data = nlspd, model = "within")

Balanced Panel: n = 10, T = 624, N = 6240

Residuals:
       Min.     1st Qu.      Median     3rd Qu.        Max. 
-7.8706e-02 -9.0319e-03  3.8278e-05  8.9624e-03  1.1349e-01 

Coefficients:
                         Estimate Std. Error t-value  Pr(>|t|)    
I(beta_MKT_RF * MKT_RF) 1.0023818  0.0072942 137.422 < 2.2e-16 ***
I(beta_HML * HML)       0.9985867  0.0527123  18.944 < 2.2e-16 ***
I(beta_SMB * SMB)       0.9731437  0.0355880  27.345 < 2.2e-16 ***
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Total Sum of Squares:    18.067
Residual Sum of Squares: 1.5037
R-Squared:      0.91677
Adj. R-Squared: 0.91661
F-statistic: 7808.71 on 3 and 623 DF, p-value: < 2.22e-16

I can also get the fixed-effect intercepts ai by using:

summary(fixef(reg1), vcov =function(x) vcovSCC(x, type="HC3", maxlag=12))
      Estimate  Std. Error t-value  Pr(>|t|)    
1   0.00127680  0.00062245  2.0512  0.040285 *  
2   0.00136923  0.00062251  2.1995  0.027877 *  
3   0.00104805  0.00062246  1.6837  0.092283 .  
4   0.00132979  0.00062259  2.1359  0.032727 *  
5  -0.00061048  0.00062252 -0.9807  0.326795    
6   0.00085262  0.00062247  1.3697  0.170816    
7  -0.00104724  0.00062250 -1.6823  0.092557 .  
8  -0.00089731  0.00062275 -1.4409  0.149672    
9  -0.00174805  0.00062292 -2.8062  0.005028 ** 
10 -0.00271173  0.00062343 -4.3497 1.385e-05 ***

Now I want to do the joint wald test on these coefficients to test whether for every i: H0: ai =0 and b=1.

Aucun commentaire:

Enregistrer un commentaire