[S] question about (codes of) categorical data and logistic regressio

Oudshoorn K. (K.Oudshoorn@pg.tno.nl)
Wed, 11 Nov 1998 16:35:16 +0100


Hello,

I have two questions:
1) Suppose we have a categorical variable which is coded internally by Splus
(starting from 1, 2 etc).
Now I want to make another vector with the SAME categories but I only have
the codes for that
factor. So if 1 corresponds to e.g. FEMALE , 2 corresponds to MALE and I
have the vector
(1, 1, 2, 1, 2, 2), what is an elegant and fast way to make the categorical
vector
(FEMALE, FEMALE, MALE, FEMALE,MALE,MALE)?

2) Does anyone know how a categorical variable (with two categories off
course) is handled
in glm.fit? Does 0 correspond with the category with the smallest code?

Thanks in advance,

Karin Oudshoorn
-----------------------------------------------------------------------
This message was distributed by s-news@wubios.wustl.edu. To unsubscribe
send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
message: unsubscribe s-news