Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
From | Richard Goldstein <richgold@ix.netcom.com> |
To | statalist@hsphsun2.harvard.edu |
Subject | Re: st: cascading dummies |
Date | Mon, 01 Oct 2012 14:39:47 -0400 |
Hi, neither is wrong or right -- they answer slightly different questions; A asks for each dummy whether, and by how, much it is different from the reference group (you do realize that you should only include 4 of the dummies, right?); B asks whether each differs from the preceding level you can -findit cascade- to find a program I wrote to implement cascading dummies; the help file, and even more the STB article, discusses the differences; note that you can obtain the answer to either question by following up the original method of forming the variables with the appropriate -test- command(s) Rich On 10/1/12 2:31 PM, Shikha Sinha wrote: > Hi all, > > Recently, I came across a new way of creating dummies and I wonder > what the group thinks about this form. > > The independent variable X is coded as 1- very poor, and 5 as very > rich. I want to estimate the effect by wealth quintile. I created the > dummy the following ways, but I was told that this is wrong (A is > wrong). The correct way to construct dummy is B and is called > cascading dummies. I have never come across this before and would > appreciate if you could shed light on the difference between the two > and which is the correct way of creating dummies. > > A: > id Y X1 (scale of 1-5), dum1 dum2 dum3 dum4 dum5 > 1 100 5 0 0 0 0 1 > 2 200 4 0 0 0 1 0 > 3 300 3 0 0 1 0 0 > 4 239 2 0 1 0 0 0 > 5 345 1 1 0 0 0 0 > > > B: > id Y X1 (scale of 1-5), dum1 dum2 dum3 dum4 dum5 > 1 100 5 1 1 1 1 1 > 2 200 4 1 1 1 1 0 > 3 300 3 1 1 1 0 0 > 4 239 2 1 1 0 0 0 > 5 345 1 1 0 0 0 0 > > Thanks, > Shikha * * For searches and help try: * http://www.stata.com/help.cgi?search * http://www.stata.com/support/faqs/resources/statalist-faq/ * http://www.ats.ucla.edu/stat/stata/