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

I'm using proc survey logistic to find the odds ratios for a given dichotomous outcome given a particular variable of interest while also controlling for several other confounding variables (age, etc.). Needless to say, I'm using complex survey data, which leaves me with a problem. 

 

I'm trying to limit my analysis to a specific group of respondents (let's say people who bought ice cream in a cone and added chocolate sprinkles). For initial prevalence estimates, I'm using domain analysis. But I know with complex survey data, you're not supposed to set datasets using BY variables because it messes up the estimates; what is an option for running logistic regression while trying to limit the analysis to a certain group? Would also controlling for that specific variable--adding it alongside the others--work? Can I add it as a domain variable?  I have several variables I want to control for, so running proc surveyfreq with multiple cross-tabbed domains would be messy. 

1 ACCEPTED SOLUTION

Accepted Solutions
ballardw
Super User

Create a class variable to identify the population of interest with an additional level of "not interested", place the variable on the Domain statement, ignore the results for the "not interested" levels.

View solution in original post

3 REPLIES 3
ballardw
Super User

Create a class variable to identify the population of interest with an additional level of "not interested", place the variable on the Domain statement, ignore the results for the "not interested" levels.

SAS93
Quartz | Level 8

Thank you! 

I guess I wasn't aware you could also use domain statements in regression analysis. I'm still new to the inter-workings of complex survey data, but this makes sense for sure. 

SAS93
Quartz | Level 8

Update: solved my own problem. 🙂 

 

I wasn't aware you could also use domain statements with regression. 

Note to anyone else who might have this issue in the future: you can. 

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

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
  • 3 replies
  • 594 views
  • 1 like
  • 2 in conversation