BookmarkSubscribeRSS Feed
Flexluthorella
Obsidian | Level 7

I have an HIV dataset that I need to pull patient records within specific timeframe of their appointment date, within 3 months prior & 14 days after ARV startdate. No Idea how to do this. 

Dates are in DATE9. format. 

 

2 REPLIES 2
Reeza
Super User
Does the ARV start date change between the individual users?

You can start by describing the problem in a bit more detail, explicitly showing what you have and what you want as output. If you can't provide real data, very common, you can make some fake data in Excel to share that looks close enough to your real data. How your data is structured is important to how the solution is derived.

Flexluthorella
Obsidian | Level 7

I need to create a cohort of patients whose CD4 measurement on appointment date is within 3 months prior to ARV start and 14 days. There may be multiple records per patient_ID within that time frame that have a CD4 measurement. Once I have this cohort, I need to select record with the minimum CD4 for those patient_ID who have >1 record. I've attached dataset. Please note this is FAKE DATA. 

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 350 views
  • 0 likes
  • 2 in conversation