Announcement

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

  • xtreg - baseline values for explanatory variables

    Is there a way to set baseline values for explanatory variables when one is undertaking an xtreg in Stata16?

    If an xtreg is undertaken without setting baseline values, then is the baseline zero for explanatory variables? Or is it the mean of that explanatory variable?

  • #2
    Sunita:
    I'm not clear with the gist of your query.
    Could you please elaborate or provide an example? Thanks.
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3
      Hi Dr. Lazzaro,

      Thank you for your kindness!

      I am sorry I did not make myself clear. I have the results from xtreg - The dependent variable is LnWords (i.e. natural log of the Number of words in a CSR report), a continuous variable. One of the explanatory variables is FirmAge, also a continuous variable.

      The coefficient and p-value that I obtained from this xtreg is as follows: coeff = 0.00286 p-value < 0.01.

      Since the dependent variable is LnWords, I interpreted this coefficient as follows: If firm age increases by 1 year, Words (in the CSR report) increases by [exp(0.00286) -1] 0.29%. Thus, if firm age increases by 50 years, the number of Words (in the CSR report) will increase by 14.5% [50 * 0.29/100 = 0.145 or 14.5%]. That is, older firms use approximately 14.5% more words in their CSR report.

      However, now the question is whether the increase of 50 years is from the base of zero years or from mean of the explanatory variable (FirmAge). I am not able to tell whether xtreg sets a baseline of zero for explanatory variables or whether the baseline is the mean of FirmAge.

      I would be grateful for any help I can get.


      Comment


      • #4
        Sunita: Because you are assuming the model is linear for LnWords, the effect is the same no matter what you choose as a base. But I would compute it a bit differently. In Section 6.2 of my introductory econometrics book, I show that the following calculation is correct:

        Code:
        di exp(.00286*50) - 1
        .1537298
        So it is about 15.4 percent. If you use a different base -- say, age = 20, and increase by 50 -- you will get the same answer.

        If you want a standard error and confidence interval to go with that, you can use

        Code:
        nlcom exp(_b[age]) - 1
        Finally, it is not the same to estimate a linear model for LnWords and an exponential model for Words. You can use xtpoisson, fe to do the latter, and it is fully robust. You will get an estimate that, if there is no heteroskedasticity n the LnWords equation, that is comparable to what you have now.

        JW

        Comment


        • #5
          Hi Dr. Wooldridge,

          I greatly appreciate your detailed explanation. I just ordered your introductory econometrics book and I will change the calculation in my paper.

          May I ask the following question?

          We did not set out to use the exponential model for Words. We are just following the literature. I used xtreg on six models, three of which have dependent variables that are Ln. The other three dependent variables are continuous variables without any math function transformation.

          Do you recommend that we should be using xtpoisson, fe for all those models that have dependent variables that are Ln?

          In this context, I wonder if the following is relevant: I started out by using xtreg, fe and found out that our sample has a bunch of variables that do not vary over time (FirmAge,
          NoofBussegments, NoofForeignsegments, NYSE, IndSector), and, so are getting dropped from the xtreg, fe model. In contrast, the random-effects model can accommodate indep variables that are constant over time. I also performed the Hausman test (here the null hyp is that the fixed-effects coefficients and the random-effects coefficients do not statistically differ), which came out with a significant result, suggesting that the fixed-effects coefficients and the random-effects coefficients do statistically differ.

          So, we had two options: 1. Drop the above variables, or, 2. Proceed with the random-effects models. We chose the latter.

          I would be very grateful for some advice.

          Comment


          • #6
            I would use the correlated random effects approach so that you can include variables that do not change across time along with those that do. It's simple: for each i, using the egen command to obtain the within-unit averages of those variables that have some variation across i and t. Include those time averages with everything else and estimate by RE. Use a cluster-robust vce option. The joint significance of the time averages is a robust version of the Hausman test.

            I talk about this in Chapter 14 of my introductory book.

            BTW, the CRE models can be estimated using the user-written command xthybrid. I haven't used it, as it's easy to generate the within-group averages directly.
            Last edited by Jeff Wooldridge; 24 Aug 2020, 20:16.

            Comment


            • #7
              Hi Dr. Wooldridge,

              Thank you again. Your advice is extremely valuable!

              I will read chapter 14 of your book when it arrives and do what you suggest.

              Comment


              • #8
                If x1 ... xJ have some time variation and xJp1 ... xK do not -- or are something like firm age -- then here's the code:

                Code:
                xtset firmid year
                egen x1b = mean(x1), by(firmid)
                ...
                egen xJb = mean(xJ), by(firmid)
                xtreg y x1 x2 ... xJ xJp1 ... xK x1b ... xJb, re vce(cluster firmid)
                test x1b ... xJb
                You can't include full year dummies because those would knock out the age variable.
                Last edited by Jeff Wooldridge; 25 Aug 2020, 14:43.

                Comment


                • #9
                  Dear Prof. Wooldridge,

                  Thank you so much again! I am very grateful!

                  Comment

                  Working...
                  X