Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: Graphs for Regression Discontinuity Designs


From   Austin Nichols <[email protected]>
To   [email protected]
Subject   Re: st: Graphs for Regression Discontinuity Designs
Date   Tue, 31 May 2011 16:24:17 -0400

andreas nordset <[email protected]>:
If you plan to use -rd- (from SSC) you should start with its help
file, noting that the version from 2010 is now called -rd_obs- with
its own help file.  In particular, bandwidth is not a documented
option, whereas bwidth is, and scopt is an option documented there.

Alternatively, you can construct your own estimates using -lpoly- as
discussed in http://www.stata-journal.com/sjpdf.html?articlenum=st0136

On Tue, May 31, 2011 at 2:54 PM, andreas nordset
<[email protected]> wrote:
> Dear Statalist members,
>
> I'm trying to figure out how to best do graphs for a Regression
> Discontinuity Design in Stata.
>
> In the Statalist archives I found this earlier suggestion by Austin
> Nichols, in response to an inquiry by Jen Zhen:
> http://www.stata.com/statalist/archive/2010-11/msg00131.html
>
> He suggests the following example code, which already does most of
> what I'd like to do
> (I have written some commands longer, and have also switched to a
> rectangular kernel to try this out):
>
> webuse nhanes2, clear
> gen bmi=weight/height^2*10000
> gen z=bmi-35
> gen bin=z-mod(z,5)+2.5
> egen mean=mean(highbp), by(bin)
> rd highbp z if inrange(z,-15,15), bandwidth(15) graph mbw(100)
> scopt(ms(i) xli(0)||scatter mean bin) line(xti(BMI less 35))
> kernel(rectangular)
>
> However, I am still struggling to add confidence intervals to the
> fitted lines, because apparently I cannot just add something like
> -lfitci- to this command. Would anyone happen to know how to do this?
>
> Besides, I didn't manage to figure out what the "ms(i)" stands for and
> what other things I could change. Typing -help scopt- didn't give me
> any results, and in the return to -help scatter- I didn't really find
> what I was looking for, so I was wondering whether there are any other
> good resources to look up such things?
>
> Thanks a lot and best regards,
> Andreas
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index