Announcement

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

  • Is it possible to make the Hausman specification test by comparing two-way error component models?

    Good morning.
    I would like to know if the comparison between the two-way effect random effects error component model and the two-way effect fixed effects error component model is possible to run in the Hausman specification test.
    Here is my command:
    Code:
    *Two-way random effects error component model | Two-way fixed effects error component model Hausman test
    xtreg firm_performance intangible_assets enterprise_value market_capitalization leverage stock_growth dividend_payout_ratio stock_volatility i.year i.industry_n, re
    estimates store random
    xtreg firm_performance intangible_assets enterprise_value market_capitalization leverage stock_growth dividend_payout_ratio stock_volatility i.year i.industry_n, fe
    estimates store fixed
    hausman fixed random
    Last edited by Lucas Bordure; 21 Jun 2021, 04:28.

    Lucas BORDURE
    Student MSc. in International Finance
    Rennes School of Business
    Stata SE 16.1

  • #2
    Is your data at the firm level? It is a common misconception that you can add additional random effects using dummies. This applies only to fixed effects. xtreg can estimate a two level (random-intercept) model, but nothing more than that. If you want to estimate a two-way random effects model, then you have to reach for mixed. Then you can use the Hausman test to compare both sets of results. However, you are making very strong assumptions by not clustering your standard errors. You need to justify these assumptions.
    Last edited by Andrew Musau; 21 Jun 2021, 07:41.

    Comment


    • #3
      Stata does not have a two way random effects model in the -xtreg- set. I guess -xtmixed- can do it, but I am not an expert on the latter command so you will have to read the manual yourself to figure out how.

      Otherwise yes, I see no reason why it should be impossible to use Hausman test on two way models.

      Comment


      • #4
        I've got this error:

        "no coefficients in common; specify equations(matchlist)
        for problems with different equation names."

        when i run this command:

        Code:
        *Two-way random effects model
        mixed firm_performance intangible_assets enterprise_value market_capitalization leverage stock_growth dividend_payout_ratio stock_volatility || industry_n:
        estimates store random
        *Two-way fixed effects model
        xtreg firm_performance intangible_assets enterprise_value market_capitalization leverage stock_growth dividend_payout_ratio stock_volatility i.year i.industry_n
        estimates store fixed
        hausman fixed random

        Lucas BORDURE
        Student MSc. in International Finance
        Rennes School of Business
        Stata SE 16.1

        Comment


        • #5
          I'd recommend against this sort of test, but before commenting further it would be very helpful to know the sizes of N and T. I also wonder how your "mixed" command is accounting for year to be treated as a "random effect."

          Comment


          • #6
            Dear Jeff Wooldridge,
            My N=120
            My T=11

            I also wonder how your "mixed" command is accounting for year to be treated as a "random effect."
            For me, year is time effect. And time effect was part of the two-way error component random effect model.

            Lucas BORDURE
            Student MSc. in International Finance
            Rennes School of Business
            Stata SE 16.1

            Comment


            • #7
              *TWO-WAY RE

              Code:
              mixed firm_performance intangible_assets - stock_volatility || _all: R.industry_n || _all: R.year, mle

              With your data dimensions, it still remains a hard sell not clustering your standard errors.

              Comment


              • #8
                Agree with Andrew on clustering. And with that data structure, I don't see how you can get away with using time dummies for the year effects. The random effects assumption for the time effects is essentially assuming that none of your x variables or y trends over time -- whether up, down, or U shape, or some other complicated pattern. It's really a non-starter. Put in year dummies and then you might want to compare RE and FE. However, FE is the way to go unless your estimates are so imprecise as to be useless. If you show the results I'd be happy to weigh in.

                Are some firms changing industry over time? If not, putting in the industry dummies is redundant with firm FE.

                The default should be

                Code:
                xtset firm_n
                xtreg firm_performance intangible_assets enterprise_value market_capitalization leverage stock_growth dividend_payout_ratio stock_volatility i.year, fe vce(cluster firm_n)
                Nothing else is as convincing, no matter what a Hausman test shows.

                Comment


                • #9
                  If I understand, I don't put time dummies in the random effect model?
                  If I understand, I put time dummies in fixed effect model?

                  I believed that in two-way error component models (random or fixed), time dummies and individual dummies were used both.

                  My firms don't change of industry over time.

                  Lucas BORDURE
                  Student MSc. in International Finance
                  Rennes School of Business
                  Stata SE 16.1

                  Comment


                  • #10
                    You put time dummies into both RE and FE. The interesting question is whether the heterogeneity is correlated with the Xs. That's what the Hausman test is meant to do. But the degrees-of-freedom will be wrong because of the time dummies. They shouldn't count. Only the variables that change across i and t count.

                    Comment


                    • #11
                      Originally posted by Joro Kolev View Post
                      Stata does not have a two way random effects model in the -xtreg- set. I guess -xtmixed- can do it, but I am not an expert on the latter command so you will have to read the manual yourself to figure out how.

                      Otherwise yes, I see no reason why it should be impossible to use Hausman test on two way models.
                      Dear all,

                      I am working with panel data.

                      I did the tests and they suggest fixed effect adjustment. However, analyzing the model and context, I cannot safely discard the variable effect.

                      1) With these tests, is it possible to safely say that I only have a fixed effect?

                      2) How is the code to see the mixed effect (fixed and random effect at the same time)? So how do I do xtreg fe and re, what is the "xtreg" for the mixed effect? xtmixed?

                      I appreciate any help. Thanks a lot!

                      Banco = Bank = id
                      Data = date/time (semesters)
                      $dependente = dependent
                      $explicativas = independent variables

                      Code:
                      xtreg $dependente $explicativas, fe
                      
                      Fixed-effects (within) regression               Number of obs      =      3534
                      Group variable: banco                           Number of groups   =       186
                      
                      R-sq:  within  = 0.5596                         Obs per group: min =         1
                             between = 0.5303                                        avg =      19.0
                             overall = 0.5155                                        max =        38
                      
                                                                      F(22,3326)         =    192.07
                      corr(u_i, Xb)  = -0.1482                        Prob > F           =    0.0000
                      
                               rho |  .67080754   (fraction of variance due to u_i)
                      ------------------------------------------------------------------------------
                      F test that all u_i=0:     F(185, 3326) =    15.88           Prob > F = 0.0000
                      Code:
                      xtreg $dependente $explicativas, re theta
                      
                      Random-effects GLS regression                   Number of obs      =      3534
                      Group variable: banco                           Number of groups   =       186
                      
                      R-sq:  within  = 0.5572                         Obs per group: min =         1
                             between = 0.7092                                        avg =      19.0
                             overall = 0.6631                                        max =        38
                      
                                                                      Wald chi2(22)      =   4680.29
                      corr(u_i, X)   = 0 (assumed)                    Prob > chi2        =    0.0000
                      
                      ------------------- theta --------------------
                        min      5%       median        95%      max
                      0.2381   0.3606     0.7094     0.8126   0.8126
                      
                       rho |  .41958416   (fraction of variance due to u_i)
                      Code:
                      quietly xtreg $dependente $explicativas, re
                      
                      xttest0
                      
                      Breusch and Pagan Lagrangian multiplier test for random effects
                      
                              inter[banco,t] = Xb + u[banco] + e[banco,t]
                      
                              Estimated results:
                                               |       Var     sd = sqrt(Var)
                                      ---------+-----------------------------
                                         inter |   480.5217        21.9208
                                             e |   84.10534       9.170897
                                             u |   60.79998       7.797434
                      
                              Test:   Var(u) = 0
                                                   chibar2(01) =  5715.62
                                                Prob > chibar2 =   0.0000
                      Code:
                       quietly xtreg $dependente $explicativas, fe
                      estimates store fixed
                      quietly xtreg $dependente $explicativas, re
                      estimates store random
                      
                      Note: the rank of the differenced variance matrix (19) does not equal the number of coefficients being tested (22); 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.
                      
                                                 b = consistent under Ho and Ha; obtained from xtreg
                                  B = inconsistent under Ha, efficient under Ho; obtained from xtreg
                      
                          Test:  Ho:  difference in coefficients not systematic
                      
                                       chi2(19) = (b-B)'[(V_b-V_B)^(-1)](b-B)
                                                =  -992.36    chi2<0 ==> model fitted on these
                                                              data fails to meet the asymptotic
                                                              assumptions of the Hausman test;
                                                              see suest for a generalized test
                      Code:
                      hausman fixed random, sigmamore
                      
                       b = consistent under Ho and Ha; obtained from xtreg
                                  B = inconsistent under Ha, efficient under Ho; obtained from xtreg
                      
                          Test:  Ho:  difference in coefficients not systematic
                      
                                       chi2(19) = (b-B)'[(V_b-V_B)^(-1)](b-B)
                                                =      123.82
                                      Prob>chi2 =      0.0000
                      Code:
                      hausman fixed random, sigmaless
                      
                       b = consistent under Ho and Ha; obtained from xtreg
                                  B = inconsistent under Ha, efficient under Ho; obtained from xtreg
                      
                          Test:  Ho:  difference in coefficients not systematic
                      
                                       chi2(19) = (b-B)'[(V_b-V_B)^(-1)](b-B)
                                                =      127.54
                                      Prob>chi2 =      0.0000
                      Code:
                      xi: xtreg $dependente $explicativas, re
                      
                      xtoverid
                      
                      Test of overidentifying restrictions: fixed vs random effects
                      Cross-section time-series model: xtreg re   
                      Sargan-Hansen statistic 127.820  Chi-sq(22)   P-value = 0.0000
                      Code:
                      Testing for time-fixed effects
                      
                      xtreg $dependente $explicativas i.data, fe
                      
                      Fixed-effects (within) regression               Number of obs      =      3534
                      Group variable: banco                           Number of groups   =       186
                      
                      R-sq:  within  = 0.5679                         Obs per group: min =         1
                             between = 0.5260                                        avg =      19.0
                             overall = 0.5098                                        max =        38
                      
                                                                      F(57,3291)         =     75.87
                      corr(u_i, Xb)  = -0.1572                        Prob > F           =    0.0000
                      
                       rho |  .67554064   (fraction of variance due to u_i)
                      ------------------------------------------------------------------------------
                      F test that all u_i=0:     F(185, 3291) =    15.95           Prob > F = 0.0000
                      
                      
                      testparm i.data
                      
                      F( 36,  3291) =    2.46
                                  Prob > F =    0.0000
                      Code:
                      Wald test
                      
                      xttest3
                      
                      Modified Wald test for groupwise heteroskedasticity
                      in fixed effect regression model
                      
                      H0: sigma(i)^2 = sigma^2 for all i
                      
                      chi2 (186)  =   1.5e+32
                      Prob>chi2 =      0.0000
                      Code:
                      Wooldridge test
                      
                      xtserial $dependente $explicativas, output
                      
                      Linear regression                                      Number of obs =    3294
                                                                             F( 21,   177) =   44.75
                                                                             Prob > F      =  0.0000
                                                                             R-squared     =  0.5291
                                                                             Root MSE      =  7.7268
                      
                                                      (Std. Err. adjusted for 178 clusters in banco)
                      
                      Wooldridge test for autocorrelation in panel data
                      H0: no first-order autocorrelation
                          F(  1,     170) =     14.070
                                 Prob > F =      0.0002
                      
                      . 
                      . 
                      . 
                      . xtserial $dependente $explicativas
                      
                      Wooldridge test for autocorrelation in panel data
                      H0: no first-order autocorrelation
                          F(  1,     170) =     14.070
                                 Prob > F =      0.0002
                      Code:
                      Trying MIXED EFFECT MODEL
                      
                       xtmixed $dependente $explicativas|| banco:
                      
                      Performing EM optimization: 
                      
                      Performing gradient-based optimization: 
                      
                      Iteration 0:   log likelihood = -13101.186  
                      Iteration 1:   log likelihood = -13101.186  
                      
                      Computing standard errors:
                      
                      Mixed-effects ML regression                     Number of obs      =      3534
                      Group variable: banco                           Number of groups   =       186
                      
                                                                      Obs per group: min =         1
                                                                                     avg =      19.0
                                                                                     max =        38
                      
                      
                                                                      Wald chi2(22)      =   4628.55
                      Log likelihood = -13101.186                     Prob > chi2        =    0.0000
                      
                      
                      ------------------------------------------------------------------------------
                        Random-effects Parameters  |   Estimate   Std. Err.     [95% Conf. Interval]
                      -----------------------------+------------------------------------------------
                      banco: Identity              |
                                         sd(_cons) |   9.789867   .5879408       8.70276    11.01277
                      -----------------------------+------------------------------------------------
                                      sd(Residual) |   9.159925   .1122329      8.942573     9.38256
                      ------------------------------------------------------------------------------
                      LR test vs. linear regression: chibar2(01) =  1512.54 Prob >= chibar2 = 0.0000
                      
                      . 
                      . 
                      . 
                      . estat ic
                      
                      -----------------------------------------------------------------------------
                             Model |    Obs    ll(null)   ll(model)     df          AIC         BIC
                      -------------+---------------------------------------------------------------
                                 . |   3534           .   -13101.19     25     26252.37    26406.63
                      -----------------------------------------------------------------------------
                                     Note:  N=Obs used in calculating BIC; see [R] BIC note

                      Comment


                      • #12
                        Allan: Just use fixed effects and cluster your standard errors to account for serial correlation. Admittedly, it's hard to give you other advice because you don't show the output that matters: the estimated coefficients and confidence intervals. Running all of those tests is noise once you know you have to use fixed effects.

                        Comment


                        • #13
                          Originally posted by Jeff Wooldridge View Post
                          Allan: Just use fixed effects and cluster your standard errors to account for serial correlation. Admittedly, it's hard to give you other advice because you don't show the output that matters: the estimated coefficients and confidence intervals. Running all of those tests is noise once you know you have to use fixed effects.
                          Dear, Jeff Wooldridge
                          Thankyou for your answer!

                          Here is the completed code

                          Subtitle:
                          Banco = Bank = id
                          Data = date/time (semesters)
                          $dependente = dependent
                          $explicativas = independent variables

                          Code:
                          *========================= ESTIMADOR DE EFEITOS FIXOS =========================
                          . *teste de CHOW
                          .
                          . xtreg $dependente $explicativas, fe
                           
                          Fixed-effects (within) regression               Number of obs      =      3534
                          Group variable: banco                           Number of groups   =       186
                           
                          R-sq:  within  = 0.5596                         Obs per group: min =         1
                                 between = 0.5303                                        avg =      19.0
                                 overall = 0.5155                                        max =        38
                           
                                                                          F(22,3326)         =    192.07
                          corr(u_i, Xb)  = -0.1482                        Prob > F           =    0.0000
                           
                          ------------------------------------------------------------------------------
                                 inter |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
                          -------------+----------------------------------------------------------------
                                    v1 |  -6.934438   2.117205    -3.28   0.001    -11.08559   -2.783283
                                    v2 |   4.882984   2.542846     1.92   0.055     -.102716    9.868684
                                    v3 |   67.64443   2.049863    33.00   0.000     63.62531    71.66355
                                    v4 |   .3831291   .0621725     6.16   0.000     .2612289    .5050294
                                    v5 |   8.788123   11.82267     0.74   0.457    -14.39232    31.96856
                                    v6 |  -1.352919   1.006036    -1.34   0.179    -3.325431    .6195925
                                    v7 |  -.0002855   .0002561    -1.11   0.265    -.0007876    .0002167
                                    v8 |  -21.53611   1.895777   -11.36   0.000    -25.25312    -17.8191
                                    v9 |  -.0009577   .0005602    -1.71   0.087    -.0020561    .0001407
                                   v10 |  -.2887443   .0960853    -3.01   0.003    -.4771366    -.100352
                                   v11 |   1.103769   1.168471     0.94   0.345    -1.187225    3.394764
                                   v12 |   .7773185   .2449676     3.17   0.002     .2970161    1.257621
                                   v14 |  -5.217405   1.470318    -3.55   0.000    -8.100224   -2.334586
                                   v15 |   2.981397   1.862894     1.60   0.110    -.6711373    6.633931
                                   v16 |   3.773943   6.038419     0.62   0.532    -8.065449    15.61333
                                   v17 |    .535882    .436962     1.23   0.220    -.3208595    1.392624
                                   v18 |   37.72751   9.948457     3.79   0.000      18.2218    57.23323
                                   v19 |  -45.12017   3.779811   -11.94   0.000    -52.53116   -37.70918
                                   v21 |   45.17704   2.063937    21.89   0.000     41.13033    49.22376
                                   v22 |   -.067528   .0483883    -1.40   0.163    -.1624019    .0273458
                                   v23 |   48.02018   9.599176     5.00   0.000     29.19929    66.84107
                                   v24 |   1.23e-08   1.71e-09     7.21   0.000     8.96e-09    1.57e-08
                                 _cons |   5.691604   14.38328     0.40   0.692    -22.50936    33.89257
                          -------------+----------------------------------------------------------------
                               sigma_u |  13.091392
                               sigma_e |  9.1708966
                                   rho |  .67080754   (fraction of variance due to u_i)
                          ------------------------------------------------------------------------------
                          F test that all u_i=0:     F(185, 3326) =    15.88           Prob > F = 0.0000

                          Code:
                          *========================= ESTIMADOR DE EFEITOS ALEATÓRIOS =========================
                          . xtreg $dependente $explicativas, re theta
                           
                          Random-effects GLS regression                   Number of obs      =      3534
                          Group variable: banco                           Number of groups   =       186
                           
                          R-sq:  within  = 0.5572                         Obs per group: min =         1
                                 between = 0.7092                                        avg =      19.0
                                 overall = 0.6631                                        max =        38
                           
                                                                          Wald chi2(22)      =   4680.29
                          corr(u_i, X)   = 0 (assumed)                    Prob > chi2        =    0.0000
                           
                          ------------------- theta --------------------
                            min      5%       median        95%      max
                          0.2381   0.3606     0.7094     0.8126   0.8126
                           
                          ------------------------------------------------------------------------------
                                 inter |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
                          -------------+----------------------------------------------------------------
                                    v1 |  -5.125656    1.97626    -2.59   0.009    -8.999054   -1.252258
                                    v2 |   4.829306   2.512329     1.92   0.055    -.0947693    9.753381
                                    v3 |   66.35121   1.914631    34.65   0.000     62.59861    70.10382
                                    v4 |   .5113285   .0573408     8.92   0.000     .3989427    .6237143
                                    v5 |   6.348042   11.84897     0.54   0.592    -16.87551    29.57159
                                    v6 |  -1.369849   1.004979    -1.36   0.173    -3.339571    .5998729
                                    v7 |  -.0002238   .0002561    -0.87   0.382    -.0007256    .0002781
                                    v8 |  -19.12462   1.827927   -10.46   0.000    -22.70729   -15.54194
                                    v9 |  -.0005529   .0005259    -1.05   0.293    -.0015837     .000478
                                   v10 |  -.2899256   .0933122    -3.11   0.002    -.4728141   -.1070371
                                   v11 |   1.689392   1.151047     1.47   0.142    -.5666185    3.945402
                                   v12 |   .9701752   .2413045     4.02   0.000      .497227    1.443123
                                   v14 |  -6.311447   1.451728    -4.35   0.000    -9.156781   -3.466113
                                   v15 |   5.509521    .900591     6.12   0.000     3.744395    7.274647
                                   v16 |   12.36448   .8036462    15.39   0.000     10.78936     13.9396
                                   v17 |   .4697527   .4404013     1.07   0.286    -.3934179    1.332923
                                   v18 |   40.78611   10.00732     4.08   0.000     21.17212     60.4001
                                   v19 |  -48.28812   3.699366   -13.05   0.000    -55.53874   -41.03749
                                   v21 |   44.81132   1.998229    22.43   0.000     40.89486    48.72778
                                   v22 |  -.0568349    .048768    -1.17   0.244    -.1524186    .0387487
                                   v23 |   51.57671   9.493769     5.43   0.000     32.96927    70.18416
                                   v24 |   1.27e-08   1.64e-09     7.75   0.000     9.51e-09    1.60e-08
                                 _cons |  -19.04766   3.598371    -5.29   0.000    -26.10034   -11.99499
                          -------------+----------------------------------------------------------------
                               sigma_u |  7.7974341
                               sigma_e |  9.1708966
                          
                                   rho |  .41958416   (fraction of variance due to u_i)
                          Code:
                          *========================= BREUSCH-PAGAN LM (multiplicador de lagrange)=========================
                          . *test for random effects versus OLS(pooled)
                          .
                          . *rodar o modelo random
                          . quietly xtreg $dependente $explicativas, re
                           
                          .
                          . *comando para rodar a comparação entre o random e o OLS
                          . xttest0
                           
                          Breusch and Pagan Lagrangian multiplier test for random effects
                           
                                  inter[banco,t] = Xb + u[banco] + e[banco,t]
                           
                                  Estimated results:
                                                   |       Var     sd = sqrt(Var)
                                          ---------+-----------------------------
                                             inter |   480.5217        21.9208
                                                 e |   84.10534       9.170897
                                                 u |   60.79998       7.797434
                           
                                  Test:   Var(u) = 0
                                                       chibar2(01) =  5715.62
                                                    Prob > chibar2 =   0.0000

                          Code:
                          *============= TESTE DE HAUSMAN (for fixed versus random effects model) =============
                          . quietly xtreg $dependente $explicativas, fe
                          . estimates store fixed
                          . quietly xtreg $dependente $explicativas, re
                          . estimates store random
                           
                          . hausman fixed random
                           
                          Note: the rank of the differenced variance matrix (19) does not equal the number of coefficients being tested (22); 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))
                                       |     fixed        random       Difference          S.E.
                          -------------+----------------------------------------------------------------
                                    v1 |   -6.934438    -5.125656       -1.808783        .7595746
                                    v2 |    4.882984     4.829306        .0536783        .3927654
                                    v3 |    67.64443     66.35121        1.293218        .7322054
                                    v4 |    .3831291     .5113285       -.1281994        .0240304
                                    v5 |    8.788123     6.348042        2.440081               .
                                    v6 |   -1.352919    -1.369849        .0169298        .0461086
                                    v7 |   -.0002855    -.0002238       -.0000617        5.22e-06
                                    v8 |   -21.53611    -19.12462       -2.411493        .5026465
                                    v9 |   -.0009577    -.0005529       -.0004048         .000193
                                   v10 |   -.2887443    -.2899256        .0011813        .0229177
                                   v11 |    1.103769     1.689392       -.5856226        .2010341
                                   v12 |    .7773185     .9701752       -.1928567        .0422046
                                   v14 |   -5.217405    -6.311447        1.094042        .2330702
                                   v15 |    2.981397     5.509521       -2.528124        1.630739
                                   v16 |    3.773943     12.36448       -8.590535        5.984702
                                   v17 |     .535882     .4697527        .0661293               .
                                   v18 |    37.72751     40.78611       -3.058592               .
                                   v19 |   -45.12017    -48.28812        3.167951         .775672
                                   v21 |    45.17704     44.81132        .3657229        .5166412
                                   v22 |    -.067528    -.0568349       -.0106931               .
                                   v23 |    48.02018     51.57671       -3.556535        1.418635
                                   v24 |    1.23e-08     1.27e-08       -4.24e-10        4.65e-10
                          ------------------------------------------------------------------------------
                                                     b = consistent under Ho and Ha; obtained from xtreg
                                      B = inconsistent under Ha, efficient under Ho; obtained from xtreg
                           
                              Test:  Ho:  difference in coefficients not systematic
                           
                                           chi2(19) = (b-B)'[(V_b-V_B)^(-1)](b-B)
                                                    =  -992.36    chi2<0 ==> model fitted on these
                                                                  data fails to meet the asymptotic
                                                                  assumptions of the Hausman test;
                                                                  see suest for a generalized test
                          Code:
                          hausman fixed random, sigmamore
                           
                          Note: the rank of the differenced variance matrix (19) does not equal the number of coefficients being tested (22); 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))
                                       |     fixed        random       Difference          S.E.
                          -------------+----------------------------------------------------------------
                                    v1 |   -6.934438    -5.125656       -1.808783        .8435136
                                    v2 |    4.882984     4.829306        .0536783        .5902281
                                    v3 |    67.64443     66.35121        1.293218        .8137951
                                    v4 |    .3831291     .5113285       -.1281994        .0263343
                                    v5 |    8.788123     6.348042        2.440081         1.89034
                                    v6 |   -1.352919    -1.369849        .0169298        .1803009
                                    v7 |   -.0002855    -.0002238       -.0000617        .0000447
                                    v8 |   -21.53611    -19.12462       -2.411493        .6004505
                                    v9 |   -.0009577    -.0005529       -.0004048         .000216
                                   v10 |   -.2887443    -.2899256        .0011813        .0283261
                                   v11 |    1.103769     1.689392       -.5856226        .2853074
                                   v12 |    .7773185     .9701752       -.1928567        .0598552
                                   v14 |   -5.217405    -6.311447        1.094042        .3452792
                                   v15 |    2.981397     5.509521       -2.528124        1.662374
                                   v16 |    3.773943     12.36448       -8.590535        6.075461
                                   v17 |     .535882     .4697527        .0661293        .0520976
                                   v18 |    37.72751     40.78611       -3.058592        1.340276
                                   v19 |   -45.12017    -48.28812        3.167951        1.015159
                                   v21 |    45.17704     44.81132        .3657229        .6283263
                                   v22 |    -.067528    -.0568349       -.0106931        .0057785
                                   v23 |    48.02018     51.57671       -3.556535        2.186001
                                   v24 |    1.23e-08     1.27e-08       -4.24e-10        5.51e-10
                          ------------------------------------------------------------------------------
                                                     b = consistent under Ho and Ha; obtained from xtreg
                                      B = inconsistent under Ha, efficient under Ho; obtained from xtreg
                           
                              Test:  Ho:  difference in coefficients not systematic
                           
                                           chi2(19) = (b-B)'[(V_b-V_B)^(-1)](b-B)
                                                    =      123.82
                                          Prob>chi2 =      0.0000
                          Code:
                          . hausman fixed random, sigmaless
                           
                          Note: the rank of the differenced variance matrix (19) does not equal the number of coefficients being tested (22); 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))
                                       |     fixed        random       Difference          S.E.
                          -------------+----------------------------------------------------------------
                                    v1 |   -6.934438    -5.125656       -1.808783         .831131
                                    v2 |    4.882984     4.829306        .0536783        .5815637
                                    v3 |    67.64443     66.35121        1.293218        .8018488
                                    v4 |    .3831291     .5113285       -.1281994        .0259477
                                    v5 |    8.788123     6.348042        2.440081         1.86259
                                    v6 |   -1.352919    -1.369849        .0169298        .1776542
                                    v7 |   -.0002855    -.0002238       -.0000617         .000044
                                    v8 |   -21.53611    -19.12462       -2.411493         .591636
                                    v9 |   -.0009577    -.0005529       -.0004048        .0002129
                                   v10 |   -.2887443    -.2899256        .0011813        .0279103
                                   v11 |    1.103769     1.689392       -.5856226        .2811192
                                   v12 |    .7773185     .9701752       -.1928567        .0589765
                                   v14 |   -5.217405    -6.311447        1.094042        .3402106
                                   v15 |    2.981397     5.509521       -2.528124        1.637971
                                   v16 |    3.773943     12.36448       -8.590535        5.986274
                                   v17 |     .535882     .4697527        .0661293        .0513328
                                   v18 |    37.72751     40.78611       -3.058592        1.320601
                                   v19 |   -45.12017    -48.28812        3.167951        1.000256
                                   v21 |    45.17704     44.81132        .3657229        .6191026
                                   v22 |    -.067528    -.0568349       -.0106931        .0056937
                                   v23 |    48.02018     51.57671       -3.556535        2.153911
                                   v24 |    1.23e-08     1.27e-08       -4.24e-10        5.43e-10
                          ------------------------------------------------------------------------------
                                                     b = consistent under Ho and Ha; obtained from xtreg
                                      B = inconsistent under Ha, efficient under Ho; obtained from xtreg
                           
                              Test:  Ho:  difference in coefficients not systematic
                           
                                           chi2(19) = (b-B)'[(V_b-V_B)^(-1)](b-B)
                                                    =      127.54
                                          Prob>chi2 =      0.0000

                          Comment

                          Working...
                          X