Announcement

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

  • How to test if the error term has conditional mean zero

    Hi, I am currently working on my undergraduate dissertation and I am using a fixed effects model. I have run my regression but I've got some very odd results so I was wondering if someone could tell me how to test if my model meets the assumption of the errors having a conditional mean of zero.

    Thanks in advance,
    Guest
    Last edited by sladmin; 17 May 2021, 06:38. Reason: anonymize original poster

  • #2
    Guest:
    questions like this one are really difficult to reply, as you do not give interested listers any detail of what is the potential problem.
    As per FAQ, please share what you typed and what Stata gave you back via CODE delimiters. Thanks.
    In addition,the same source can provide you with some relevant (and time saving) hints on how to post effectively on this forum.
    That said, I'm a bit suprised that your main concern is about the (systematic?) error rather than your model specification.
    Last edited by sladmin; 17 May 2021, 06:38. Reason: anonymize original poster
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3
      Hi Carlo, I made this post because I am trying to explore any possible reason for the odd results I am getting when I run my regression. I have read a lot of the literature related to my study so I do not believe my model specification is the issue. I was hoping to be told a command I can use following
      Code:
      xtreg, fe
      that would tell me the conditional mean of the error term of my regression.

      Kind Regards,
      Guest
      Last edited by sladmin; 17 May 2021, 06:38. Reason: anonymize original poster

      Comment


      • #4
        Guest:
        if you share your seemingly weird results via CODE delimiters, positive replies will be more likely.
        Again, I fail to follow your concern about conditional mean=0 of the systematic error.
        Last edited by sladmin; 17 May 2021, 06:38. Reason: anonymize original poster
        Kind regards,
        Carlo
        (Stata 19.0)

        Comment


        • #5
          Hi, I have shared my results on another post. I was asking about the conditional mean because I didn't know if failing to meet that assumption was a potential cause of my strange results. Apologies for wasting your time if I was misguided in thinking this.

          Kind Regards,
          Guest
          Last edited by sladmin; 17 May 2021, 06:38. Reason: anonymize original poster

          Comment


          • #6
            A deviation could be an explanation for unexpected results. It obviously depends on the exact deviations.
            ---------------------------------
            Maarten L. Buis
            University of Konstanz
            Department of history and sociology
            box 40
            78457 Konstanz
            Germany
            http://www.maartenbuis.nl
            ---------------------------------

            Comment


            • #7
              The short answer is that in exactly identified models you cannot test the assumption that the error has mean zero, because the residuals (our only measure of the unobserved errors), have mean zero conditional on the covariates by constructions. Here:

              Code:
              . sysuse auto, clear
              (1978 Automobile Data)
              
              . reg price mpg headroom
              
                    Source |       SS           df       MS      Number of obs   =        74
              -------------+----------------------------------   F(2, 71)        =     10.44
                     Model |   144280501         2  72140250.4   Prob > F        =    0.0001
                  Residual |   490784895        71  6912463.32   R-squared       =    0.2272
              -------------+----------------------------------   Adj R-squared   =    0.2054
                     Total |   635065396        73  8699525.97   Root MSE        =    2629.2
              
              ------------------------------------------------------------------------------
                     price |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
              -------------+----------------------------------------------------------------
                       mpg |  -259.1057   58.42485    -4.43   0.000    -375.6015   -142.6098
                  headroom |  -334.0215   399.5499    -0.84   0.406    -1130.701    462.6585
                     _cons |   12683.31   2074.497     6.11   0.000     8546.885    16819.74
              ------------------------------------------------------------------------------
              
              . predict e, resid
              
              . reg e mpg headroom
              
                    Source |       SS           df       MS      Number of obs   =        74
              -------------+----------------------------------   F(2, 71)        =      0.00
                     Model |           0         2           0   Prob > F        =    1.0000
                  Residual |   490784891        71  6912463.25   R-squared       =    0.0000
              -------------+----------------------------------   Adj R-squared   =   -0.0282
                     Total |   490784891        73   6723080.7   Root MSE        =    2629.2
              
              ------------------------------------------------------------------------------
                         e |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
              -------------+----------------------------------------------------------------
                       mpg |   3.70e-06   58.42485     0.00   1.000    -116.4958    116.4958
                  headroom |  -3.72e-06   399.5499    -0.00   1.000    -796.6799    796.6799
                     _cons |  -.0000735   2074.497    -0.00   1.000     -4136.43     4136.43
              ------------------------------------------------------------------------------
              
              .
              The slopes and the constant in the second regression of the residuals on the regressors are all mighty zeros. This does not mean anything, our first regress command made them like this by construction.

              Comment


              • #8
                Thanks, everyone for the help, I've realised the problem lies elsewhere.

                Comment

                Working...
                X