Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Husman test

    Hi please i have a question related to Husman test, when we run random effect model in the Husman test do we need to control for industry or this step we take it after the result of the Husman test support using Random effect. i give an example.


    this example i did not add industry.

    xtreg percacatagebondwh CSO FSIZE ROA SD_OCF LEV DIV BSIZE BIND ESG_combinedwh PSIZE DPP RPP DR MA i.year , fe
    estimate store fe
    xtreg percacatagebondwh CSO FSIZE ROA SD_OCF LEV DIV BSIZE BIND ESG_combinedwh PSIZE DPP RPP DR MA i.year , re
    estimates store re
    hausman fe re


    This example i add industry as control variable in the random effect regression.

    xtreg percacatagebondwh CSO FSIZE ROA SD_OCF LEV DIV BSIZE BIND ESG_combinedwh PSIZE DPP RPP DR MA i.year , fe
    estimate store fe
    xtreg percacatagebondwh CSO FSIZE ROA SD_OCF LEV DIV BSIZE BIND ESG_combinedwh PSIZE DPP RPP DR MA i.year I. industry , re
    estimates store re
    hausman fe re


    What is the appropriate way??

  • #2
    Hussein:
    1) -hausman- pick up solely the coefficients shared by both codes; therefore, -i.industry- would be ruled out from -hausman- in both instances;
    2) in your second code -I.industry- should be -i.industry-.
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3
      Thanks a lot professor Carlo

      Please as i understand from your notes that (industry )should not be used in Husman test.
      . please i would like to ask should (year) be use in both fixed effect and random effect in Husman test???. so mainly our Husman test


      xtreg percacatagebondwh CSO FSIZE ROA SD_OCF LEV DIV BSIZE BIND ESG_combinedwh PSIZE DPP RPP DR MA i.year , fe
      estimate store fe
      xtreg percacatagebondwh CSO FSIZE ROA SD_OCF LEV DIV BSIZE BIND ESG_combinedwh PSIZE DPP RPP DR MA i.year , re
      estimates store re
      hausman fe re

      Comment


      • #4
        Hussein:
        you should use -i.year- in the right-hand side of yourb regression equations.
        The only issue with -hausman- comparison between -fe- and -re- estimators, is the fact that only the regressors that are shared between the two regression equationbs will be taken into account (see -i.race- case in the following toy-example):
        Code:
        . . use "https://www.stata-press.com/data/r17/nlswork.dta"
        (National Longitudinal Survey of Young Women, 14-24 years old in 1968)
         
        . xtreg ln_wage c.age##c.age i.race i.year, fe
        note: 2.race omitted because of collinearity.
        note: 3.race omitted because of collinearity.
        
        Fixed-effects (within) regression               Number of obs     =     28,510
        Group variable: idcode                          Number of groups  =      4,710
        
        R-squared:                                      Obs per group:
             Within  = 0.1162                                         min =          1
             Between = 0.1078                                         avg =        6.1
             Overall = 0.0932                                         max =         15
        
                                                        F(16,23784)       =     195.45
        corr(u_i, Xb) = 0.0613                          Prob > F          =     0.0000
        
        ------------------------------------------------------------------------------
             ln_wage | Coefficient  Std. err.      t    P>|t|     [95% conf. interval]
        -------------+----------------------------------------------------------------
                 age |   .0728746   .0107894     6.75   0.000     .0517267    .0940224
                     |
         c.age#c.age |  -.0010113    .000061   -16.57   0.000    -.0011309   -.0008917
                     |
                race |
              Black  |          0  (omitted)
              Other  |          0  (omitted)
                     |
                year |
                 69  |   .0647054   .0158222     4.09   0.000     .0336928     .095718
                 70  |   .0284423   .0234621     1.21   0.225     -.017545    .0744295
                 71  |   .0579959   .0326524     1.78   0.076    -.0060048    .1219967
                 72  |   .0510671   .0422995     1.21   0.227    -.0318426    .1339769
                 73  |   .0424104    .052118     0.81   0.416    -.0597442    .1445651
                 75  |   .0151376   .0717194     0.21   0.833    -.1254371    .1557123
                 77  |   .0340933   .0918106     0.37   0.710    -.1458613    .2140478
                 78  |   .0537334   .1023339     0.53   0.600    -.1468475    .2543143
                 80  |   .0369475   .1221806     0.30   0.762    -.2025343    .2764293
                 82  |   .0391687   .1423573     0.28   0.783    -.2398606     .318198
                 83  |    .058766   .1523743     0.39   0.700    -.2398974    .3574294
                 85  |   .1042758   .1726431     0.60   0.546    -.2341157    .4426673
                 87  |   .1242272   .1930108     0.64   0.520    -.2540863    .5025406
                 88  |   .1904977   .2068016     0.92   0.357    -.2148466     .595842
                     |
               _cons |   .3937532   .2001741     1.97   0.049     .0013992    .7861072
        -------------+----------------------------------------------------------------
             sigma_u |  .40275174
             sigma_e |  .30127563
                 rho |  .64120306   (fraction of variance due to u_i)
        ------------------------------------------------------------------------------
        F test that all u_i=0: F(4709, 23784) = 8.75                 Prob > F = 0.0000
        
        . estimates store fe
        
        . xtreg ln_wage c.age##c.age i.race i.year, re
        
        Random-effects GLS regression                   Number of obs     =     28,510
        Group variable: idcode                          Number of groups  =      4,710
        
        R-squared:                                      Obs per group:
             Within  = 0.1161                                         min =          1
             Between = 0.1245                                         avg =        6.1
             Overall = 0.1116                                         max =         15
        
                                                        Wald chi2(18)     =    3757.34
        corr(u_i, X) = 0 (assumed)                      Prob > chi2       =     0.0000
        
        ------------------------------------------------------------------------------
             ln_wage | Coefficient  Std. err.      z    P>|z|     [95% conf. interval]
        -------------+----------------------------------------------------------------
                 age |   .0790911   .0039765    19.89   0.000     .0712973    .0868848
                     |
         c.age#c.age |  -.0011036   .0000586   -18.84   0.000    -.0012184   -.0009888
                     |
                race |
              Black  |  -.1251588   .0127093    -9.85   0.000    -.1500685   -.1002491
              Other  |   .0940173   .0529605     1.78   0.076    -.0097834    .1978181
                     |
                year |
                 69  |   .0648079   .0124419     5.21   0.000     .0404223    .0891936
                 70  |   .0263438   .0120155     2.19   0.028     .0027938    .0498938
                 71  |   .0537732   .0125423     4.29   0.000     .0291908    .0783556
                 72  |   .0482933   .0136268     3.54   0.000     .0215853    .0750013
                 73  |    .038056   .0144537     2.63   0.008     .0097272    .0663847
                 75  |    .006932   .0169468     0.41   0.683    -.0262832    .0401472
                 77  |   .0276061   .0199382     1.38   0.166    -.0114721    .0666842
                 78  |   .0492717    .021678     2.27   0.023     .0067837    .0917597
                 80  |   .0309794   .0248624     1.25   0.213    -.0177499    .0797087
                 82  |   .0296793   .0279688     1.06   0.289    -.0251386    .0844972
                 83  |   .0521756   .0296308     1.76   0.078    -.0058997    .1102509
                 85  |   .0997798   .0329073     3.03   0.002     .0352827     .164277
                 87  |   .1196681   .0363187     3.29   0.001     .0484848    .1908515
                 88  |   .1842637   .0386857     4.76   0.000     .1084411    .2600862
                     |
               _cons |   .3198597   .0604665     5.29   0.000     .2013475    .4383719
        -------------+----------------------------------------------------------------
             sigma_u |  .35862524
             sigma_e |  .30127563
                 rho |  .58625495   (fraction of variance due to u_i)
        ------------------------------------------------------------------------------
        
        . estimates store re
        
        . hausman fe re
        
        Note: the rank of the differenced variance matrix (15) does not equal the number of coefficients being tested (16); be sure this is what you expect, or there may be problems
                computing the test.  Examine the output of your estimators for anything unexpected and possibly consider scaling your variables so that the coefficients are on a
                similar scale.
        
                         ---- Coefficients ----
                     |      (b)          (B)            (b-B)     sqrt(diag(V_b-V_B))
                     |       fe           re         Difference       Std. err.
        -------------+----------------------------------------------------------------
                 age |    .0728746     .0790911       -.0062165        .0100299
         c.age#c.age |   -.0010113    -.0011036        .0000922        .0000171
                year |
                 69  |    .0647054     .0648079       -.0001025        .0097746
                 70  |    .0284423     .0263438        .0020984        .0201519
                 71  |    .0579959     .0537732        .0042228        .0301475
                 72  |    .0510671     .0482933        .0027738        .0400445
                 73  |    .0424104      .038056        .0043545        .0500737
                 75  |    .0151376      .006932        .0082056        .0696885
                 77  |    .0340933     .0276061        .0064872        .0896195
                 78  |    .0537334     .0492717        .0044617        .1000114
                 80  |    .0369475     .0309794        .0059681        .1196243
                 82  |    .0391687     .0296793        .0094894        .1395827
                 83  |     .058766     .0521756        .0065904        .1494656
                 85  |    .1042758     .0997798         .004496        .1694779
                 87  |    .1242272     .1196681         .004559         .189563
                 88  |    .1904977     .1842637         .006234         .203151
        ------------------------------------------------------------------------------
                                  b = Consistent under H0 and Ha; obtained from xtreg.
                   B = Inconsistent under Ha, efficient under H0; obtained from xtreg.
        
        Test of H0: Difference in coefficients not systematic
        
           chi2(15) = (b-B)'[(V_b-V_B)^(-1)](b-B)
                    =  89.25
        Prob > chi2 = 0.0000
        
        .
        Se aside any comments on the correct model specification, -i.race- is nit included in the set of coefficients listed in -hausman- table, as it is a time-invariant regressor that cannot be estimated with -fe-.
        More substantively, please call me Carlo, just like all on (and many more off) this list do. Thanks.
        Kind regards,
        Carlo
        (Stata 19.0)

        Comment

        Working...
        X