BookmarkSubscribeRSS Feed
joebaker7
Calcite | Level 5

Hi,

If I have the following model:

proc logistic data=joe.extra2 order=formatted;

class tt (ref='<=2')/param=ref;

class race (ref='white')/param=ref;

class clinic (ref='austin')/param=ref;

class sex (ref='female')/param=ref;

model a1ctri=tt race age clinic ;

strata sex;

where  sex ne . and race ne . and clinic ne . and age ne . and bmi ne . and smokingnew ne . and htn ne . and depression ne .

and dyslipidemia ne . and language ne . and insurance ne . and med ne . and visits ne . and years ne .;

format a1ctri a1ctri. tt tt. med med. sex sex. race race. clinic clinic. insurance insurance.

htn htn. dyslipidemia dyslipidemia. depression depression.;

run;

and I want to get stratified results by SEX, with an odds ratio for each, how do I do it?  Just by specifying in the 'where' statement that sex=0?

Thanks

1 REPLY 1
1zmm
Quartz | Level 8

Use PROC SORT to sort by sex.  Then insert a   BY sex; statement in your PROC LOGISTIC code.  Be sure to drop the STRATA statement because that has a different purpose.

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 2030 views
  • 0 likes
  • 2 in conversation