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]
st: ICE conditional option and categorical variables
From
A Loumiotis <[email protected]>
To
[email protected]
Subject
st: ICE conditional option and categorical variables
Date
Thu, 18 Nov 2010 16:39:48 +0200
Hi,
I have a question in ICE. Suppose I have five continuous variables
(var1-var5) and a categorical variable (call it catvar1 with 3) all
with some observations missing. Suppose also that catvar1 defines
conditions for other variables to be answered ie, var1: catvar1==1,
var2: catvar1==2, var3: catvar1==4.
In the following ice command is the conditional option correct?
ice var1-var5 m.catvar1, ... cond(var1: catvar1==1, var2:
catvar1==2, var3: catvar1==4)
Or should I transform it in terms of the corresponding dummy variables
of catvar1 and adjust the mainvarlist accordingly?
ice var1-var5 catvar1a catvar1b, ... cond(var1: catvar1a==1, var2:
catvar1b==1, var3: catvar1a==0 & catvar1b==0)
where catvar1a=1 if catvar1==1
and catvar1b=1 if catvar1==2
It seems to me that the latter is the case but I'm not sure. For sure
if the latter is the case then matters are complicated when someone
has many categorical variables as basis for conditions.
Thanks,
Antonis Loumiotis
*
* 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/