Announcement

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

  • Breusch-Pagan Test

    Hello

    I am trying to do a Breusch-Pagan test to test for heteroscedasticity. I have two regression models with different dependent variables but with the same independent variables as follows

    Code:
    regress viol_crime_rate asylum_pop a8_pop lnpop benefit_claimants young_share
    regress prop_crime_rate asylum_pop a8_pop lnpop benefit_claimants young_share
    Should I do it as follows

    Code:
    regress viol_crime_rate asylum_pop a8_pop lnpop benefit_claimants young_share
    estat hettest, fstat
    
    regress prop_crime_rate asylum_pop a8_pop lnpop benefit_claimants young_share
    estat hettest, fstat
    Is this right?

    or should I make just one test, since both models have the same independent but just different dependent variable as follows


    Code:
    ​​​​​​​estat hettest asylum_pop a8_pop lnpop benefit_claimants young_share
    I am confused, which way I should prefer and If the dependent variables play an important role.



    Thank you very much for your help.
    Last edited by Lucca Mancini; 03 Sep 2019, 01:30.

  • #2
    Lucca:
    since OLS residual are observed minus predicted values, you should expect that the residuals of your regression models will differ:
    Code:
    use "http://www.stata-press.com/data/r15/auto.dta"
    
    . reg price weight
    
          Source |       SS           df       MS      Number of obs   =        74
    -------------+----------------------------------   F(1, 72)        =     29.42
           Model |   184233937         1   184233937   Prob > F        =    0.0000
        Residual |   450831459        72  6261548.04   R-squared       =    0.2901
    -------------+----------------------------------   Adj R-squared   =    0.2802
           Total |   635065396        73  8699525.97   Root MSE        =    2502.3
    
    ------------------------------------------------------------------------------
           price |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
    -------------+----------------------------------------------------------------
          weight |   2.044063   .3768341     5.42   0.000     1.292857    2.795268
           _cons |  -6.707353    1174.43    -0.01   0.995     -2347.89    2334.475
    ------------------------------------------------------------------------------
    
    . estat hettest
    
    Breusch-Pagan / Cook-Weisberg test for heteroskedasticity 
             Ho: Constant variance
             Variables: fitted values of price
    
             chi2(1)      =    13.76
             Prob > chi2  =   0.0002
    
    . reg mpg weight
    
          Source |       SS           df       MS      Number of obs   =        74
    -------------+----------------------------------   F(1, 72)        =    134.62
           Model |   1591.9902         1   1591.9902   Prob > F        =    0.0000
        Residual |  851.469256        72  11.8259619   R-squared       =    0.6515
    -------------+----------------------------------   Adj R-squared   =    0.6467
           Total |  2443.45946        73  33.4720474   Root MSE        =    3.4389
    
    ------------------------------------------------------------------------------
             mpg |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
    -------------+----------------------------------------------------------------
          weight |  -.0060087   .0005179   -11.60   0.000    -.0070411   -.0049763
           _cons |   39.44028   1.614003    24.44   0.000     36.22283    42.65774
    ------------------------------------------------------------------------------
    
    . estat hettest
    
    Breusch-Pagan / Cook-Weisberg test for heteroskedasticity 
             Ho: Constant variance
             Variables: fitted values of mpg
    
             chi2(1)      =    11.05
             Prob > chi2  =   0.0009
    Hence, I would perform two different -estat hettest-.

    In addition, as your regression models share the same set of predictors, I woould consider -sureg-:
    Code:
    . sureg (price weight) (mpg weight)
    
    Seemingly unrelated regression
    --------------------------------------------------------------------------
    Equation             Obs   Parms        RMSE    "R-sq"       chi2        P
    --------------------------------------------------------------------------
    price                 74       1    2468.262    0.2901      30.24   0.0000
    mpg                   74       1      3.3921    0.6515     138.36   0.0000
    --------------------------------------------------------------------------
    
    ------------------------------------------------------------------------------
                 |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
    -------------+----------------------------------------------------------------
    price        |
          weight |   2.044063   .3717069     5.50   0.000      1.31553    2.772595
           _cons |  -6.707353    1158.45    -0.01   0.995    -2277.228    2263.813
    -------------+----------------------------------------------------------------
    mpg          |
          weight |  -.0060087   .0005108   -11.76   0.000    -.0070099   -.0050075
           _cons |   39.44028   1.592043    24.77   0.000     36.31994    42.56063
    ------------------------------------------------------------------------------
    
    .
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment

    Working...
    X