Announcement

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

  • Using weighted least squares on Heteroskedasticity

    I used the Breusch-Pagan to check for Heteroskedasticity which I found (1st attachment). Then I used weighted least squares to mitigate it. I did this by trial and error and used the code [aw=1/experience]. I have attached the results (2nd attachment) . Does the 2nd image still show Heteroskedasticity?

    Also I am running two regressions this one(the images attached) is for return to education for white ethnicity in the UK and my other regression which does not have any heterskedascity is for returns to education for ethnic minorities in the UK. Although I do not have any Heteroskedasticity in the ethnic minorities regression do I still need to use weighted least squares. As both regressions run the same variables and I don't want to create any bias in either one.

    I am new to stata and any responses will be very appreciated
    Attached Files

  • #2
    Dawud:
    please start sharing what you typed and what Stata gave you back via CODE delimiters (as per FAQ, that also remind listers that screenshots are deprecated,mainly because it is impossible to work/elaborate on them). Thanks.
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3
      Originally posted by Carlo Lazzaro View Post
      Dawud:
      please start sharing what you typed and what Stata gave you back via CODE delimiters (as per FAQ, that also remind listers that screenshots are deprecated,mainly because it is impossible to work/elaborate on them). Thanks.
      Hello,
      Thank you for letting me know I will do that.

      Comment


      • #4
        Dear Dawud Sikander,

        I have some comments and suggestions on this:

        1 - You should use robust standard errors both in the OLS and WLS regressions.

        2 - You have a different number of observations in the two equations. I presume that is because experience is zero for some individuals. This suggests that your weights are not very sensible.

        3 - As an alternative, I suggest you run a Poisson regression of grsswk (not it log) on the same regressors. Again, you should use robust standard errors.

        Best wishes,

        Joao

        Comment


        • #5
          Originally posted by Joao Santos Silva View Post
          Dear Dawud Sikander,

          I have some comments and suggestions on this:

          1 - You should use robust standard errors both in the OLS and WLS regressions.

          2 - You have a different number of observations in the two equations. I presume that is because experience is zero for some individuals. This suggests that your weights are not very sensible.

          3 - As an alternative, I suggest you run a Poisson regression of grsswk (not it log) on the same regressors. Again, you should use robust standard errors.

          Best wishes,

          Joao
          Hello,
          Thank you very much for your reply

          Should I change my weights the code i used to change them was
          Code:
          [aw=1/experience]
          . I used the weights to fix my heteroskedasticty. Do you suggest I change these weights in order to fix the observations?
          Also I am unfamiliar with robust standard errors is that another way of testing heteroskedascity? Also I have a a basic understanding of Poisson regression where you predict the count?
          I am sorry for my lack of knowledge

          Comment


          • #6
            Dear Dawud Sikander,

            You should really learn about robust standard errors; please get a good textbook and study that section.

            Best wishes,

            Joao

            Comment


            • #7
              Dear Stata users,

              Please could someone let me know how to compute a WLS fixed effects regression model with robust standard errors to address heteroskedasticity in a panel data set. I have managed to compute the robust standard errors but I'm not sure how to get the WLS estimates. I have tried to but I received the following error:


              xtreg DiffMeanHourlyPercent responsible_person_changes [weight = yhat4_inv], vce(robust) fe
              (analytic weights assumed)

              'weight must be constant within CompanyNumber'


              Kind regards,

              Uyi Erhabor
              (Stata 16.1 SE)
              Last edited by Uyi Erhabor; 12 Jan 2021, 07:04.

              Comment


              • #8
                Either make the weights to be constant within panels, or if you insist on having time varying weights, do the time demeaning manually and use -regress- to fit the fixed effects regression.

                Comment

                Working...
                X