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: Interpretation of factor variables


From   Richard Williams <[email protected]>
To   [email protected], [email protected]
Subject   Re: st: Interpretation of factor variables
Date   Thu, 11 Jul 2013 10:24:50 -0500

Also, for what it is worth, I tend to avoid shortcuts and write out each term in the model, e.g.

reg y i.dummy x i.dummy#c.x

I know you can save a little typing with things like the ## notation, but if you are not careful you can leave out a term or get a different parameterization than you wanted.

In any event, if things look weird, make sure you are clear on exactly what model you estimated and how things were parameterized. It helps if you know exactly how many parameters the model should have.

At 06:31 AM 7/11/2013, Maarten Buis wrote:
The first line gives you the effect of continuous when dummy == 0 and
the second line gives you the effect of continuous when dummy == 1.
This happend because you did not enter the main effect of continuous.
This happened because you entered the main effect of dummy but not
(maybe forgot) the main effect of continuous. If you had also entered
the main effect of continous, then you would have gotten and effect of
continuous, which would mean the effect of continuous when dummy == 0,
and one interaction which would mean how much the effect of continous
when dummy == 0 differs from the effect of continous when dummy == 1.
The two models are obviously equivalent, so which one you choose
depends only on which one you find easier to interpret.

-- Maarten

On Thu, Jul 11, 2013 at 1:00 PM, Yu Chen, PhD <[email protected]> wrote:
> Dear Statalist,
> I have a dummy variable that takes values of one or zero, and a
> continuous variable. I ran the following regression.
> Dependent Variable (DV) = Dummy + Dummy*Continuous + other control
> variables. I used factor variables (i.e., i.Dummy +
> i.Dummy#c.Continuous )
> I got results as below. My question is how should I interpret the two
> lines below Dummy#c.Continuous? The first line shows a 0. I interpret
> it as Dummy takes 0 for this line. However, if Dummy takes 0, the
> whole term should be zero and should be eliminated from the results.
> But Stata still gave me a Coef. What is going on?
> Thank you in advance for your help.
>
>
> ------------------------------------------------------------------------------ > DV | Coef. Std. Err. t P>|t| [95% Conf. Interval] > -------------+----------------------------------------------------------------
> Dummy#c.Continuous |
> 0 | 31.54672 9.438251 3.34 0.001 13.04526 50.04818 > 1 | 37.70141 7.609734 4.95 0.000 22.78433 52.6185
>              |
> Dummy |   .1026062   .1648457     0.62   0.534    -.2205349    .4257472
>
>
> Yu Chen
> *
> *   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/



--
---------------------------------
Maarten L. Buis
WZB
Reichpietschufer 50
10785 Berlin
Germany

http://www.maartenbuis.nl
---------------------------------
*
*   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/

-------------------------------------------
Richard Williams, Notre Dame Dept of Sociology
OFFICE: (574)631-6668, (574)631-6463
HOME:   (574)289-5227
EMAIL:  [email protected]
WWW:    http://www.nd.edu/~rwilliam

*
*   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/


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