Paul,
"param=3D" specifies the parameterizion method for the classification =
variable. The default is param=3Deffect, but effect coding creates a =
different number of dummy variables (the same as the number of =
classifications), and different values (it includes -1 in addition to 1 =
and 0) than reference coding does. =20
Peter Flom recommends using reference coding; I do find it is easier to =
interpret the odds ratios by using it; thus param=3Dref specifies to =
create the dummy variables using reference coding, which is similary to =
how I learned to do them originally when we had to do them in the data =
step (uses 1 and 0, with 1 less dummy variable created than there are =
categories).
-Mary
----- Original Message -----=20
From: paul wilson=20
To: Mary=20
Sent: Wednesday, October 15, 2008 7:29 PM
Subject: Re: use of class statement in proc logistic
Hi Mary,
What does "param=3Dref" in your code do?
I Inderstand ref=3D'M' part but no clue what "parm" code does and if =
it's necessary.
...and yeah, you're absolutely right, I'd much rather learn how to do =
it this way then code dummies manually :)
Also, would you be able to provide an example of "by" code in proc =
logistic and explain what it does?
Thanks a lot!
----- Original Message ----
From: Mary <***@AVALON.NET>
To: SAS-***@LISTSERV.UGA.EDU
Sent: Tuesday, October 14, 2008 5:37:55 PM
Subject: Re: use of class statement in proc logistic
Nikhil,
What a class statement is doing is forming "dummy" variables to use in =
the
model. For instance, the logistic regression coding:
proc logistic data=3Dset1;
class sex(param=3Dref ref=3D'M');
model disease=3Dsex var1 var2;
run;
Would form one dummy variable for sex with values 0 for Male (because =
it was
the reference variable), and 1 for Female. If you have more than two
values, it would form one less dummy variable than you have values =
(i.e.,
two for 3 categories). It is probably a good idea to use reference =
coding
to start as I'm doing above, as effect coding is different in the way =
it
codes dummy variables and that can get confusing!
So, the class statement in logistic regression identifies the =
categorical
variables rather than doing a separate analysis (use the by statement =
for
that). When I started we had to code all our dummy variables in the =
data
step, so the introduction of the class statement was a big help!
-Mary
----- Original Message -----
From: n
To: SAS-***@LISTSERV.UGA.EDU
Sent: Tuesday, October 14, 2008 8:08 AM
Subject: use of class statement in proc logistic
hi all;
i am using the proc logistic in my work but am a bit confused about
what exactly the 'class' statement means.
it does not give any separate analysis for the class variables.
could you please tell me the function of the class statement?
thanks and regards
Nikhil