Do you have a tip that you find particularly useful? If so, you can share your handy tip(s) on PharmaSUG’s Tuesday Tips page. Submit tips about SAS, R, Python, use of CDISC standards, regulatory submissions, etc.- anything that you have found helpful and might be useful to someone else.

Tips can be submitted to the Head Data Tech Lifeguard (This email address is being protected from spambots. You need JavaScript enabled to view it.) and/or Social Media Coordinators (This email address is being protected from spambots. You need JavaScript enabled to view it.).

New tips will be published every Tuesday, while older tips will be archived and accessible to viewers on the PharmaSUG website.

Weekly Tip for Jan. 19, 2021

Use SAS Survey Procedures for Complex Survey Analysis

It is common practice when learning statistics for students to distribute a simple survey of mundane content (What is your favorite color? What is your undergraduate major?) to collect data. This data is then compiled into a small data set and used for simple statistical exploration. Considering this, it is no wonder that we tend to assume that any statistical procedure can be applied to survey data. Though there is some truth to this frame of mind, we must acknowledge that the method of collecting survey data violates a number of our favorite procedure’s most restrictive assumptions. As explained in an earlier Tuesday Tip, assumption violations effectively destroy a model’s credibility if they are not addressed.

Since survey data is so widely used, SAS sought to address the common issues with survey analysis by developing a series of seven survey specific analytic procedures:

  • PROC SURVEYSELECT: Used to select a sample from a data set.
  • PROC SURVEYIMPUTE: Used to do single imputations on a survey data set.
  • PROC SURVEYMEANS: Used to obtain weighted descriptive statistics for continuous variables and produce accompanying graphics.
  • PROC SURVEYFREQ: Used to run weighted one-way and multi-way cross-tabulations and produce accompanying graphics.
  • PROC SURVEYREGRESS: Used to run weighted OLS regressions.
  • PROC SURVEYLOGISTIC: Used to run weighted logistic, ordinal, multinomial and probit regressions.
  • PROC SURVEYPHREG: Used to run weighted proportional hazards regression.

It is important to make sure that you are using the appropriate procedure for the data you have. If you are working with survey data, please make sure to take a look at these procedures. They have built in options that allow you to manipulate your model to reduce the impact of common assumption violations.

Happy analyzing!

This week’s tip was contributed by Deanna Schreiber-Gregory. Deanna is a government contractor and independent consultant who specializes in statistics, research methods, and data management.

Past Tuesday Tips

Data Standards Tips

Submission and Regulatory Tips

Statistics and Analytics Tips

SAS Programming Tips

Miscellaneous Tips