Announcement

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

  • Predict and Robvar Functions

    Good morning and good afternoon... I was wondering if someone can help me out with a syntax of STATA commands doubt to proceed with a test for heteroskedasticity of random effects model. I am following a manual instructions and other researches that have applied the same statistical procedures and everything was going fine until I have stumbled in the following commands...

    - Xtreg variable dependiente variable independiente, re
    - Predict pred, e
    - robvar pred by (group)

    Regarding the estimation of random effects no problem at all. My doubt is on the following steps with the predict function. And especially what does mean "pred"?. Based on the the concepts of the heteroskedasticity I suppose that the command should serve to predict the standard deviation of the errors as a new variable to be used on the following step with the function robvar to test the null hypothesis for the White test is Homoskedasticity, i.e. no existence of heteroskedasticity.

    By reading several online tutorials I understood the function predict but the syntax "pred" I couldn't quite get. In other work the same sequence of instructions I found predict che, e... And I couldn't understand either.

    I would appreciate some advice on that matter.

    Cheers,

    Luiz Alfredo Santos
    [email protected]
    [email protected]
    home: (34) 911 737 091
    mobile: (34) 647 397 958

  • #2
    Hi, this is the forum for Mata - a programming language within Stata. General questions such as these should be asked in the other subforum, which is also frequented by many more people.

    That said, I think you are looking for help xtreg postestimation##predict, which details the syntax of predict after xtreg. predict <varname>, e will predict the residuals. If you want the standard error, you need to use predict <varname>, stdp. The <varname> part simply names the variable your results will be stored in, so it can be almost anything, aka predict pred, e and predict che, e will do exactly the same, except that in the first case the results will be stored in "pred", the second uses "che" as variable name.

    Comment

    Working...
    X