0
votes

In Stata I'm trying to plot the coefficients of rdrobust estimates using coefplot:

foreach depvar of varlist var1 var2 var3 var4 {
    rdrobust `depvar' running_variable, kernel(triangular) bwselect(cerrd) p(1)
    estimates store  `depvar'
}

coefplot _est_var1 _est_var2 _est_var3 _est_var4 , replace xline(0)

But I get the following error message:

estimation result _est_var1 not found

Anyone knows how to solve this?

1
Cross-posted at statalist.org/forums/forum/general-stata-discussion/general/… Telling people about cross-posting is always a good idea. - Nick Cox

1 Answers

0
votes

I have only changed the last line of your code and I wonder if it would work. As I do not have your data, I have not tested.

foreach depvar of varlist var1 var2 var3 var4{
  rdrobust `depvar' running_variable, kernel(triangular) bwselect(cerrd) p(1)
  estimates store  `depvar'
}
coefplot var1 var2 var3 var4, replace xline(0)