Announcement

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

  • Extracting the Beta Coeff from regression

    Hello all,

    I am running a linear regression, with 2 sets of dummy variables age (25-65) and cohort(1924-1991). I wanted to extract the beta coefficients from my linear regression only for the age variable. Does anyone know how I can approach this problem?

    Many Thanks.

  • #2
    Hi Nas,

    Maybe you can use "gen beta=_b[age]" and "gen se=_se[age]" to get the coeffcients.

    Best regards
    Chang

    Comment


    • #3
      Chang has it. Although if you're using Stata's factor variable notation for your indicator (dummy) variables, then you'll probably have to include the prefix. Something like
      Code:
      display in smcl as text _b[1.age]
      For more information,
      Code:
      help _variables
      and especially the hyperlink shown there to the user manual's entry [U] 13.5 Accessing coefficients and standard errors

      Comment


      • #4
        Many thanks,

        Do you know if I am able to plot the dummy variables directly?

        Comment


        • #5
          I don't really understand what you mean by "plot the dummy variables directly". How does what you're seeking differ from what you can do with, say, marginsplot?

          Edited to add: also, you might want to see whether what is pulled up by
          Code:
          search coefplot
          is pertinent to what you're trying to do.
          Last edited by Joseph Coveney; 05 Jul 2020, 18:02.

          Comment

          Working...
          X