Cross-Standard Validation

Overview

The implementation of the ADaM 2.1 standard in the SAS Clinical Standards Toolkit requires the use of a number of cross-standard validation checks. These cross-standard validation checks compare data and metadata between two different standards, such as ADaM 2.1 and SDTM 3.1.2.
The SAS Clinical Standards Toolkit provides two macros that enable cross-standard comparisons: cstcheck_crossstdcomparedomains.sas and cstcheck_crossstdmetamismatch.sas. These macros are located here: !sasroot/cstframework/sasmacro.

The %CSTCHECK_CROSSSTDCOMPAREDOMAINS Macro

The %CSTCHECK_CROSSSTDCOMPAREDOMAINS macro compares values for one or more columns in one table with those same columns in another domain in another standard. Or, it compares the values against metadata from the comparison standard. The macro requires use of _cstCodeLogic as a full DATA step or PROC SQL invocation. This DATA or SQL step assumes as input a work copy of the column metadata data set returned by the %CSTUTIL_BUILDCOLLIST macro. Any resulting records in the derived data set represent errors to be reported.
Here are example validation checks that use the %CSTCHECK_CROSSSTDCOMPAREDOMAINS macro:
  • ADaM subject not found in the SDTM DM domain
  • ADaM SDTM domain reference (for traceability), but the SDTM domain is unknown
An ADaM 2.1 validation check that uses this macro is ADAM0653. Here is the rule description for this check:
“Specified record not found in SDTM for this subject.”
Here is the message text for this check:
Corresponding SDTM record not found based on STUDYID, USUBJID and AESEQ
Here is sample code from the codelogic field from the ADaM 2.1 Validation Master data set for validation check ADAM0653. In this example, &_cstDSName (ADaM data set name) and &_cstCrossDataLib (SDTM library) are generated by the macro prior to execution of codelogic.
%let _cstCheckVar=AETERM;
	proc sql noprint;
	  create table work._cstproblems as 
	  select adam.studyid, adam.usubjid, adam.aeseq, adam.&_cstCheckVar 
	  from &_cstDSName as adam 
		 left join 
	       &_cstCrossDataLib..ae as sdtm 
		 on adam.studyid=sdtm.studyid and adam.usubjid=sdtm.usubjid and 
		    adam.aeseq=sdtm.aeseq 
	  where adam.&_cstCheckVar ne sdtm.&_cstCheckVar
	quit;

The %CSTCHECK_CROSSSTDMETAMISMATCH Macro

The %CSTCHECK_CROSSSTDMETAMISMATCH macro identifies inconsistencies in metadata across registered standards. The macro requires use of _cstCodeLogic as a full DATA step or PROC SQL invocation. This DATA step or SQL step assumes as input a work copy of the column metadata data set returned by the %CSTUTIL_BUILDCOLLIST macro. Any resulting records in the derived data set represent errors to be reported.
Assumptions:
  1. No data content is accessed for this check.
  2. Both study and reference metadata are available to assess compliance.
  3. The _cstProblems data set includes at least two columns. The mnemonics are from the global standards library data set:
    • &_cstStMnemonic._value (for example, ADAM_value containing the value of the column of interest from the primary standard)
    • &_cstCrMnemonic._value (for example, SDTM_value containing the value of the column of interest from the comparison standard)
Required global macro variables:
  • _cstcrossstd: The name of the comparison standard. It is also used as a parameter to initialize _cstCrMnemonic.
  • _cstcrossstdver: The version of the comparison standard.
  • _cstrunstd: The primary standard. It is also used as a parameter to initialize _cstStMnemonic.
  • _cstrunstdver: The version of the primary standard.
An ADaM 2.1 validation check that uses this macro is ADAM0651. Here is the rule description for this check, taken from the CDISC ADaM Validation document:
“ADaM column with a column name prefix of 'AE' not found in SDTM”
Here is the message text for this check:
ADaM column name starting with AE found having no like-named SDTM column
The full codeLogic PROC SQL step for ADAM0653 is located here:
global standards library directory/standards/cdisc-adam-2.1-1.7/validation/control/validation_master.sas7bdat