/*------------------------------------------------------------*
* program:     cdisc100.sas                                    *
* Description: Case #100. Overdose Codelist For AE domains, this identifies records where *
*              value for [Occurred with Overdose] is not found in Codelist [YESNO], *
*              limited to records where [Occurred with Overdose is not null].*
* By:          Sy Truong, 10/14/2009                          *
*-------------------------------------------------------------*/

libname datalib '../data';
options nofmterr;

data datalib.AE (label="Adverse Events");
attrib STUDYID label="Study Identifier" length=$100; 
attrib DOMAIN label="Domain Abbreviation" length=$100; 
attrib USUBJID label="Unique Subject Identifier" length=$100; 
attrib AESEQ label="Sequence Number" length=8; 
attrib AEGRPID label="Group ID" length=$100; 
attrib AEREFID label="Reference ID " length=$100; 
attrib AESPID label="Sponsor-Defined Identifier" length=$100; 
attrib AETERM label="Reported Term for the Adverse Event" length=$100; 
attrib AEMODIFY label="Modified Reported Term" length=$100; 
attrib AEDECOD label="Dictionary-Derived Term" length=$100; 
attrib AECAT label="Category for Adverse Event" length=$100; 
attrib AESCAT label="Subcategory for Adverse Event" length=$100; 
attrib AEOCCUR label="Adverse Event Occurrence" length=$100; 
attrib AEBODSYS label="Body System or Organ Class" length=$100; 
attrib AELOC label="Location of the Reaction" length=$100; 
attrib AESEV label="Severity/Intensity" length=$100; 
attrib AESER label="Serious Event" length=$100 format=$NY.; 
attrib AEACN label="Action Taken with Study Treatment" length=$100; 
attrib AEACNOTH label="Other Action Taken" length=$100; 
attrib AEREL label="Causality" length=$100; 
attrib AERELNST label="Relationship to Non-Study Treatment" length=$100; 
attrib AEPATT label="Pattern of Adverse Event" length=$100; 
attrib AEOUT label="Outcome of Adverse Event" length=$100; 
attrib AESCAN label="Involves Cancer" length=$100 ; 
attrib AESCONG label="Congenital Anomaly or Birth Defect" length=$100; 
attrib AESDISAB label="Persist or Signif Disability/Incapacity" length=$100 ; 
attrib AESDTH label="Results in Death" length=$100  ; 
attrib AESHOSP label="Requires or Prolongs Hospitalization" length=$100 ; 
attrib AESLIFE label="Is Life Threatening" length=$100 ; 
attrib AESOD label="Occurred with Overdose" length=$100  format=$NY.; 
attrib AESMIE label="Other Medically Important Serious Event" length=$100; 
attrib AECONTRT label="Concomitant or Additional Trtmnt Given" length=$100 ; 
attrib AETOXGR label="Standard Toxicity Grade" length=$100; 
attrib AESTDTC label="Start Date/Time of Adverse Event" length=$100; 
attrib AEENDTC label="End Date/Time of Adverse Event" length=$100; 
attrib AESTDY label="Study Day of Start of Adverse Event" length=8; 
attrib AEENDY label="Study Day of End of Adverse Event" length=8; 
attrib AEDUR label="Duration of Adverse Event" length=$100; 
attrib AEENRF label="End Relative to Reference Period" length=$100; 

 STUDYID  ="001"; 
 DOMAIN   ="001";
 USUBJID  ="001";
 AESEQ    =1;
 AEGRPID  ="001";
 AEREFID  ="001";
 AESPID   ="001";
 AETERM   ="001";
 AEMODIFY="001";
 AEDECOD  ="001";
 AECAT    ="001";
 AESCAT   ="001";
 AEOCCUR  ="001";
 AEBODSYS="001";
 AELOC    ="001";
 AESEV    ="001";
 AESER    ="Y";
 AEACN    ="001";
 AEACNOTH="001";
 AEREL    ="001";
 AERELNST="001";
 AEPATT   ="001";
 AEOUT    ="001";
 AESCAN   ="001";
 AESCONG  ="001";
 AESDISAB="YN";
 AESDTH   ="001";
 AESHOSP  ="001";
 AESLIFE  ="001";
 AESOD    ="001";
 AESMIE   ="001";
 AECONTRT="001";
 AETOXGR  ="001";
 AESTDTC  ="001";
 AEENDTC  ="001";
 AESTDY   ="001";
 AEENDY   =8;
 AEDUR    ="001";
 AEENRF   ="001";

run;
/*----------------------------------------------------*
* Program: cdisc.sas
* Path: C:\Program Files\SAS 9.2\SASFoundation\9.2
* Description: Verify SAS datasets against CDISC standards
* By: Jeanny Huynhh, %cdisc, 10/05/2009,  2:55:15 pm
*-----------------------------------------------------*/
*** Apply the CDISC check ***;
%cdisc (datlib=datalib,
        datname= AE);
