Announcement

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

  • Coefplot - without any FE

    Dear Statalist users,

    I'm trying to make a plot of my regression results using coefplot. I have data on export value and quantity over 24 months for 30 countries and 66 products and I run the following DID regression.
    Code:
    reg lnvalue time treated did2 did1 did didd1 didd2 didd3 didd4 didd5 i.country i.month i.product, r cluster(country)
    est store reg1
    all the different variables are either leads, lags or fixed effects and the estimates are stored as reg1.

    My regression output results in the different DID estimates and tons of FE and when I run the coefplot command:
    Code:
     coefplot reg1, vertical drop(_cons) yline(0)
    it plots not only the DID estimates but also all FE.

    I have also tried the following version based on a previous question regarding a similar problem
    Code:
    coefplot reg1, vertical keep(*.did2 *.did1 *.did *.didd1 *.didd2 *.didd3 *.didd4 *.didd5) yline(0)
    but stata responds by saying "reg1: no coefficients found, all dropped, or none kept) (nothing to plot)"

    Is there anyway of getting rid of all the FE and simply only plot the DID estimates?

    Thanks in advance!

    /Sebastian



    Last edited by Sebastian Andersson; 16 Apr 2019, 03:45.

  • #2
    You'll increase your chances of a useful answer by following the FAQ on asking questions - provide Stata code in code delimiters, readable Stata output, and sample data using dataex. Being able to replicate your problem would help use solve it specifically.

    What happens if in the last statement you change from *.did to fully specifying the dummies' names? You can get the proper name by issuing reg,coefl after the regression.

    Comment

    Working...
    X