BookmarkSubscribeRSS Feed
Jimbo
Calcite | Level 5
Hi,

Apologies if this is a repeat but can't find the answer searching.

I'm very new to SAS and have inherited a large data set to analyse.

The data is medication records in an Excel sheet. 1000 patients, with up to 15 years data for each.

Some data which should have been collected is missing - this is labelled '.'

However, some data is not recorded 'deliberately' eg because the patient died / was discharged. These observations are labeled '88'.

In the analysis I need to account for data which should have been collected, but the '88' values need to be ignored.

Does anyone have any suggestions as to how I can tell SAS not to include these observations in any analysis?

Many thanks,
Jim
2 REPLIES 2
ballardw
Super User
Type of analysis to be performed would be helpful in answering as some approaches may not work every where.

With that in mind filtering the data in the analysis procedure is a start.

proc xxxxx data= (where=( ne 88));

Some procedures allow analysis of the missing data (the '.') using an option usually MISSING. For example

proc freq data= (where=( ne 88));
table /missing;
run;

will treat missing levels as a valid category and report counts and percents as such.
Jimbo
Calcite | Level 5
Thanks very much!

I'm (planning on!) performing a survival analysis - blood pressure control to time defined end point.

I'll give the code a try now. Many thanks again,

Jim

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 16. 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
  • 2 replies
  • 960 views
  • 0 likes
  • 2 in conversation