BookmarkSubscribeRSS Feed
mosadoluwa
Calcite | Level 5

Hello,

 

I need help extracting unique ICD 10 diagnosis codes from a character variable (ICD10_with_Description):

 

Have

ICD9  ICD10_with_Description

431 I61.0 Nontraumatic intracerebral hemorrhage in hemisphere, subcortical I61.1 Nontraumatic intracerebral hemorrhage in hemisphere, cortical I61.2 Nontraumatic intracerebral hemorrhage in hemisphere

431 I61.4 Nontraumatic intracerebral hemorrhage in cerebellum I61.5 Nontraumatic intracerebral hemorrhage, intraventricular

431 I61.6 Nontraumatic intracerebral hemorrhage, multiple localized I61.8 Other nontraumatic intracerebral hemorrhage

437.7 G45.4 Transient global amnesia

 

I want a dataset with 1 var

Unique_dx

I610

I611

I612

I614

I615

I616

I618

G454

 

Thank you for your help!

2 REPLIES 2
ballardw
Super User

Do digits occur anywhere in that description other than in the codes?

 

I would be very leery of discarding that decimal. I don't use ICD codes much but would worry about complications such as

I6.11 and I61.1 ending up as the same value.

mosadoluwa
Calcite | Level 5

@ballardw Digits occur only in the codes.

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!

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
  • 422 views
  • 0 likes
  • 2 in conversation