LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (November 2010, week 4)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Thu, 25 Nov 2010 20:07:55 -0500
Reply-To:   "Viel, Kevin" <kviel@SJHA.ORG>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   "Viel, Kevin" <kviel@SJHA.ORG>
Subject:   Re: ICD9 CM Removing large blocks text
In-Reply-To:   <FA0550A1D186FF49BB0748CD711B17ED97B39FF071@SDPSMSX.QUALNET.ORG>
Content-Type:   text/plain; charset="us-ascii"

> -----Original Message----- > From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Bian, > Haikuo > Sent: Wednesday, November 24, 2010 10:41 AM > To: SAS-L@LISTSERV.UGA.EDU > Subject: Re: ICD9 CM Removing large blocks text > > I see Toby have already provided a nice PRX solution. While If you are not > familiar with PRX functions like me (still scratching my head and > learning), I just want you to know there may be other ways to tackle it. > Given the data as is, will this work for you? > > > data test; > infile cards; > length code $ 5 desc $ 250; > input @; > if notdigit(substr(_infile_,1,3)) ne 0 then delete; > else input code $ desc &$; > cards; > Crystalluria > Elevated urine levels of: > 17-ketosteroids > catecholamines > indolacetic acid > vanillylmandelic acid [VMA] > Melanuria > 792 Nonspecific abnormal findings in other body substances > Terms following the word "excludes" are to be coded elsewhere. The term > excludes means "DO NOT CODE HERE".Excludes: that in chromosomal > analysis (795.2) > 792.0 Cerebrospinal fluid > 792.1 Stool contents > Abnormal stool color > Fat in stool > Mucus in stool > Occult blood > Pus in stool > Terms following the word "excludes" are to be coded elsewhere. The term > excludes means "DO NOT CODE HERE".Excludes: blood in stool [melena] > (578.1) > newborn (772.4, 777.3) > 792.2 Semen > Abnormal spermatozoa > Terms following the word "excludes" are to be coded elsewhere. The term > excludes means "DO NOT CODE HERE".Excludes: azoospermia (606.0) > oligospermia (606.1) > 792.3 Amniotic fluid > ; > run; > proc print; > run; > > > or even without involving _infile_ variable: > > data test; > infile cards; > length code $ 5 desc $ 250; > drop first3; > input first3 $3. @1 @; > if notdigit(first3) ne 0 then delete; > else input code $ desc &$; > cards; > ... > ... > ; > run; > > HTH, > Haikuo > > -----Original Message----- > From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of toby > dunn > Sent: Thursday, November 18, 2010 2:05 PM > To: SAS-L@LISTSERV.UGA.EDU > Subject: Re: ICD9 CM Removing large blocks text > > This is untested but should lay the ground work for an easy parse. > The reason I went with PRX functions is well one I working on a > BBU book over the subject, but more importantly it is the breaking > the string into two parts that I felt was easier and would be more > efficient with the PRXPosn and PRXMatch combo. > > > FileName FLN "C:\Zenworks\Dtab09_15nov10.txt" ; > > Data ICD9_CODES ( Drop = Text Pattern ) ; > Infile FLN delimiter='09'x MISSOVER DSD Lrecl=32767 FirstObs=2 ; > Length DX_Code $8. > DX_Desc $125. ; > > Input Text $Char1000. ; > > Pattern = PRXParse( '/^([\d|.]+ (.*)$)/o' ) ; > > If ( PrxMatch( Pattern , Strip( Text ) ) > 0 ) Then Do ; > DX_Code = PrxPosn( Pattern , 1 , Text ) ; > DX_Desc = PrxPosn( Pattern , 2 , Text ) ; > Output ; > End ; > > Run ; > > > > > > > > Toby Dunn > > > "I'm a hell bent 100% Texan til I die" > > "Don't touch my Willie, I don't know you that well" > > > > > > Date: Thu, 18 Nov 2010 13:49:07 -0500 > > From: kibrown@LADHS.ORG > > Subject: ICD9 CM Removing large blocks text > > To: SAS-L@LISTSERV.UGA.EDU > > > > Hi all, > > I have an official version of ICD9 CM CD. I exported the all ICD9 codes > in > > a text file. The issue is the export from the CD creates > > a text file with ICD 9 codes, descriptions and all comments associated > > with every classification. > > > > I need only the ICD9 codes and descriptions. > > > > I have been manually deleting all commentary, which is very laborious. > I'm > > working with version 9.1 in XP pro platform. > > Any help is appreciated. Thanks, Kim > > > > Sample of files: > > Crystalluria > > Elevated urine levels of: > > 17-ketosteroids > > catecholamines > > indolacetic acid > > vanillylmandelic acid [VMA] > > Melanuria > > 792 Nonspecific abnormal findings in other body substances > > Terms following the word "excludes" are to be coded elsewhere. The term > > excludes means "DO NOT CODE HERE".Excludes: that in chromosomal > > analysis (795.2) > > 792.0 Cerebrospinal fluid > > 792.1 Stool contents > > Abnormal stool color > > Fat in stool > > Mucus in stool > > Occult blood > > Pus in stool > > Terms following the word "excludes" are to be coded elsewhere. The term > > excludes means "DO NOT CODE HERE".Excludes: blood in stool [melena] > > (578.1) > > newborn (772.4, 777.3) > > 792.2 Semen > > Abnormal spermatozoa > > Terms following the word "excludes" are to be coded elsewhere. The term > > excludes means "DO NOT CODE HERE".Excludes: azoospermia (606.0) > > oligospermia (606.1) > > 792.3 Amniotic fluid > > > > I want this: > > 792 Nonspecific abnormal findings in other body substances > > 792.0 Cerebrospinal fluid > > 792.1 Stool contents > > 792.2 Semen > > 792.3 Amniotic fluid > > > > > > I used this statement to import into SAS: > > data WORK.ICD9_CODES ; > > %let _EFIERR_ = 0; > > infile 'C:\Zenworks\Dtab09_15nov10.txt' delimiter='09'x MISSOVER DSD > > lrecl=32767 > > firstobs=2 ; > > informat dx_code $8. ; > > informat dx_desc $125. ; > > format dx_code $8. ; > > format dx_desc $125. ; > > input > > dx_code$ > > dx_desc$ ; > > run; > > > > I was trying to use something like this > > data icd9_codes2; > > set icd9_codes; > > If (char (dx_code, 1)) not in ('1', '2', '3') then dx_code2=dx_code; > > run; > > I'm open to any suggestions. > > ----------------------------------------- > Email messages cannot be guaranteed to be secure or error-free as > transmitted information can be intercepted, corrupted, lost, > destroyed, arrive late or incomplete, or contain viruses. The > Centers for Medicare & Medicaid Services therefore does not accept > liability for any error or omissions in the contents of this > message, which arise as a result of email transmission. > > CONFIDENTIALITY NOTICE: This communication, including any > attachments, may contain confidential information and is intended > only for the individual or entity to which it is addressed. Any > review, dissemination, or copying of this communication by anyone > other than the intended recipient is strictly prohibited. If you > are not the intended recipient, please contact the sender by reply > email and delete and destroy all copies of the original message.

I must admit that I have not read this thoroughly, but it is worth noting that some ICD-9 codes do start with a letter: E955, for example, which Toby unfortunately uses in his job :(

HTH,

Kevin

Kevin Viel, PhD Senior Research Statistician Patient Safety & Quality International College of Robotic Surgery Saint Joseph's Translational Research Institute

Saint Joseph's Hospital 5671 Peachtree Dunwoody Road, NE, Suite 330 Atlanta, GA 30342

(678) 843-6076: Direct Phone (678) 843-6153: Facsimile (404) 558-1364: Mobile kviel@sjha.org

Confidentiality Notice: This e-mail, including any attachments is the property of Catholic Health East and is intended for the sole use of the intended recipient(s). It may contain information that is privileged and confidential. Any unauthorized review, use, disclosure, or distribution is prohibited. If you are not the intended recipient, please delete this message, and reply to the sender regarding the error in a separate email.


Back to: Top of message | Previous page | Main SAS-L page