Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, statalist.org is already up and running.


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

Re: st: Interaction tests between categorical variables


From   Nick Cox <njcoxstata@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: Interaction tests between categorical variables
Date   Tue, 14 Aug 2012 10:49:58 +0100

You are mixing old and new syntax. Choose one or the other. See -help xi-.

Nick

On Tue, Aug 14, 2012 at 10:36 AM, Amal Khanolkar <Amal.Khanolkar@ki.se> wrote:

> I'm trying to run the following model with an interaction term between two categorical variables; motherland and education. However I get an error message when I change the baseline group of the second categorical variable, education. How do I go about avoiding the problem? (the interaction model runs if I just run it without changing the baseline group of Education).
>
> . xi: regress bviktbs i.motherland*ib2.education sex byear ib3.magecat i.parity i.famsit_new ib5.gestwk_cat6 i.smoke1 i.gestht1 i.gestht2 i.gestht3 i.gestht4 i.gestdt i.MB
>> MI2 mlangd ib6.immigyr_cat if multibirth==1
>
> factor variables and time-series operators not allowed

*
*   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–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index