sample study library directory/cdisc-sdtm-3.1.3–1.7
.
%let _cstStandard=CDISC-SDTM; %let _cstStandardVersion=3.1.3; %let _cstVersion=; %let _cstCTPath=; %let _cstCTMemname=; %let _cstCTDescription=;
%cst_setStandardProperties(_cstStandard=CST-FRAMEWORK,_cstSubType=initialize);
%cst_getRegisteredStandards(_cstOutputDS=work._cstStandards); data _null_; set work._cstStandards (where=(standard="CST-FRAMEWORK")); call symputx('_cstVersion',strip(productrevision)); run;
* Set Controlled Terminology version for this process *; %cst_getstandardsubtypes(_cstStandard=CDISC-TERMINOLOGY,_cstOutputDS=work._cstStdSubTypes); data _null_; set work._cstStdSubTypes (where=(standardversion="&_cstStandard" and isstandarddefault='Y')); * User can override CT version of interest by specifying a different where clause: *; * Example: (where=(standardversion="&_cstStandard" and standardsubtypeversion='201104')) *; call symputx('_cstCTPath',path); call symputx('_cstCTMemname',memname); call symputx('_cstCTDescription',description); run; proc datasets lib=work nolist; delete _cstStandards _cstStdSubTypes; quit;
*********************************************************************************************; * The following data step sets (at a minimum) the studyrootpath and studyoutputpath. These *; * are used to make the driver programs portable across platforms and allow the code to be *; * run with minimal modification. These macro variables by default point to locations within *; * the cstSampleLibrary, set during install but modifiable thereafter. The cstSampleLibrary *; * is assumed to allow write operations by this driver module. *; *********************************************************************************************; %cstutil_setcstsroot; data _null_; call symput('studyRootPath',cats("&_cstSRoot", "/cdisc-sdtm-3.1.3-&_cstVersion/sascstdemodata")); call symput('studyOutputPath',cats("&_cstSRoot", "/cdisc-sdtm-3.1.3-&_cstVersion/sascstdemodata")); run;
%let workPath=%sysfunc(pathname(work));
%let _cstSetupSrc=SASREFERENCES; *****************************************************************************************; * One strategy to defining the required library and file metadata for a CST process *; * is to optionally build SASReferences in the WORK library. An example of how to do *; * this follows. *; * *; * The call to cstutil_processsetup below tells CST how SASReferences will be provided *; * and referenced. If SASReferences is built in work, the call to cstutil_processsetup *; * may, assuming all defaults, be as simple as %cstutil_processsetup() *; *****************************************************************************************; *****************************************************************************************; * Build the SASReferences data set *; * column order: standard, standardversion, type, subtype, sasref, reftype, iotype, *; * filetype, allowoverwrite, relpathprefix, path, order, memname, comment *; * note that &_cstGRoot points to the Global Library root directory *; * path and memname are not required for Global Library references - defaults will be used*; ******************************************************************************************; %cst_createdsfromtemplate(_cstStandard=CST-FRAMEWORK, _cstType=control,_cstSubType=reference, _cstOutputDS=work.sasreferences); proc sql; insert into work.sasreferences values ("CST-FRAMEWORK" "1.2" "messages" "" "messages" "libref" "input" "dataset" "N" "" "" 1 "" "") values ("&_cstStandard" "&_cstStandardVersion" "control" "validation" "cntl_v" "libref" "input" "dataset" "N" "" "&studyRootPath/control" . "validation_control.sas7bdat" "") [etc.] ; quit;
&studyRootPath/control
and
sets the name to validation_control.sas7bdat. Based on the code executed
in step 1, this is the path:
sample study library directory/cdisc-sdtm-3.1.3/sascstdemodata/control/validation_control.sas7bdat
.
%cstutil_processsetup();in the validate_data.sas driver reflects the acceptance of the macro parameter defaults listed above.
*********************************************************************; * Set global macro variables for the location of the sasreferences *; * file (overrides default properties initialized above *; *********************************************************************; %let _cstSASRefsName=&_cstSASReferencesName; %let _cstSASRefsLoc=&_cstSASReferencesLocation;
* Run the standard-specific validation macro. ; %sdtm_validate;
* Clean up the SAS Clinical Standards Toolkit process files, macro variables and macros.; %cstutil_cleanupcstsession( _cstClearCompiledMacros=0, _cstClearLibRefs=0, _cstResetSASAutos=0, _cstResetCmpLib=0, _cstResetFmtSearch=0, _cstResetSASOptions=1, _cstDeleteFiles=1, _cstDeleteGlobalMacroVars=0);
Lines
|
Comment
|
---|---|
1,7,8
|
Informational notes
about processing the properties files.
|
3
|
Informational note saying
that the creation of work.sasreferences was successful.
|
4
|
Informational note from
cstutil_processsetup that informs you of the location of the SASReferences
data set.
|
5-6
|
Informational notes
that inform you that the process SASReferences data set passed internal
validation using the %CSTUTILVALIDATESASREFERENCES macro called from
two different macros.
|
9-18
|
Informational summary
that provides internal documentation about the process.
|
19-20
|
Checks SDTM0006 and
SDTM0032 ran without error.
|
21
|
Check SDTM0815 did not
run. The check scope as defined in tableScope and columnScope found
no domains other than POOLDEF in the sample study that contained the
column of interest (POOLID).
|
22-23
|
A single problem was
detected for each of the SDTM0816 and SDTM0860 checks. Actual column
values and key values for the problem records are reported to aid
in problem resolution.
|