BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
ChuksManuel
Pyrite | Level 9

Please i will appreciate if someone can help explain what happened here.

 

I ran an adjusted model to get the Odds Ratio for these variables and i could not find the OR for age :

 

proc surveylogistic data = second1;
weight fwc;
class sex (ref = '0') race(Ref = '0')age (ref= '0') premature(ref= '0') smokeInside (Ref= '0')
allergy(Ref = '0') AdultEducate (Ref = '0') ExclusiveBrstfd(Ref = '0') FPL (Ref='0');
Model asthma (event ='1') = age sex race premature allergy AdultEducate ExclusiveBrstFd FPL;
run;

 

In my initial Bivariate analysis, i got an OR for age. 

I coded age groups "0-5", "6-11" "12-17" as 0, 1 and 2 respectively with 0 as my reference group.

Please can anyone explain what happened here?

 

 

Attached is the output for the multivariate analysis without age.

 

 

 

Capture.JPGCapture1.JPG

 

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User
Show all the output, specifically, check the number of observations used as well as the design matrix.

View solution in original post

6 REPLIES 6
PeterClemmensen
Tourmaline | Level 20

Does your log show any notes/warnings?

ChuksManuel
Pyrite | Level 9

NO. The Log did not show any warnings. 

Reeza
Super User
Show all the output, specifically, check the number of observations used as well as the design matrix.
Rick_SAS
SAS Super FREQ

Use PROC FREQ to doublecheck the levels of the AGE variable. Is it possible that AGE is continuous and that you named the recoded (binned) variable something else?

ballardw
Super User

 

It may be a good idea to show HOW you created your age categories.

I have seen this behavior when someone uses code similar to

 

data have;

    set have;

   if age in (1 2 3 4 5) then age=0;

   <similar for the other age groups>

run;

 

And for some reason ran that data step more than once, perhaps adding other recodes. The first pass would reduce the age range to 0,1,2. The second would then turn the 1 and 2 "groups" to the 0 group. So all values of "age" are now 0 and with one value 0 DF

 

ChuksManuel
Pyrite | Level 9

Thank you very much. 

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 Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 6 replies
  • 1868 views
  • 2 likes
  • 5 in conversation