Announcement

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

  • Is there a way to show coefficients of multiple regressions in the same diagram?

    I have these four regressions:

    Code:
    reg log_wage y2013 y2014 y2015 y2016 y2017 y2018 y2019 if state=="AL"
    reg log_wage y2013 y2014 y2015 y2016 y2017 y2018 y2019 if state=="GA"
    reg log_wage y2013 y2014 y2015 y2016 y2017 y2018 y2019 if state=="FL"
    reg log_wage y2013 y2014 y2015 y2016 y2017 y2018 y2019 if state=="SC"
    What I am currently doing is: making an Excel sheet table from all these coefficients, and making a twoway line graph with the four lines representing the four states, with year (y2012-y2019) in the x-axis.

    Is there a way to do that using -coefplot- or -twoway line- or any other command?

    Thanks so much!

  • #2
    maybe this is useful,
    Code:
    sysuse auto, clear
    eststo f0: reg price i.rep78 if foreign==0
    eststo f1: reg price i.rep78 if foreign==1
    coefplot (f0,c(l)) (f1,c(l)), keep(*rep78) vertical

    Comment

    Working...
    X