Announcement

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

  • Endogeneity in Stata

    Good night! I have a doubt and I would be very thankful if you could help me out.

    I am estimating a model (panel data) where my Y is the stock_index and I have 6 explanatory variables. When testing endogeneity, I needed to use an instrument for that (is the only way, right?). For every endogenous variable, I found an instrument where F>10. This is one example of what I did for each variable:

    reg stock_index pop_dis gdp yield hours_worked gov_trust pop_educ, robust
    reg pop_dis secur gdp yield hours_worked gov_trust pop_educ, robust
    predict vhat6, xb
    reg stock_index vhat6 gdp yield hours_worked gov_trust pop_educ, robust
    test vhat6=0

    My question is, after doing this for every variable, which command do I use to put it all together in a regression? I tested something like: "reg stock_index vhat gdp vhat3 vhat4 vhat5 vhat6, robust" but a friend told me that´s not the correct formula (but also didn´t know the correct one).

    Can you help me, please?

  • #2
    Someone? Please?

    Comment


    • #3
      Filipa:
      you should take a look at -xtivreg-.
      In addition, why using -regress- as your fitst choice for panel data analysis? Why not considering -xtreg-?
      Kind regards,
      Carlo
      (Stata 18.0 SE)

      Comment


      • #4
        Filipa, I am not in a position to help you with this question since this isn't really my area of expertise. That said, I don't think you're going to win any friends by reposting your question in private messages to random posters. If you haven't gotten an answer and you're wondering why, please read through the FAQ above, paying particular attention to sections 15 and 17.

        Comment


        • #5
          Thank you so much, Dr. Carlo!

          Just to confirm, by using the command: "xtivreg stock_index vhat gdp vhat3 vhat4 vhat5 vhat6", being the vhats estimated after the xtreg of the endogenous variable in function of their instruments, we will estimate the correct model to correct the endogeneity?

          Thank you once again, and have a lovely week!

          With my best regards,
          Filipa Silva.

          Comment

          Working...
          X