CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data...

52
CDM CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR

Transcript of CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data...

Page 1: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 1

SAS in Pharmaceutical Industry

30 July 2009

Arjun Roy&

Madan Gopal KunduClinical Data Management & Biostatistics

MACR

Page 2: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 2

Statistical software

SAS – Advantage, History, Definition, Windows

Basic Programming

SAS Macro, Examples

Validation, Compliance

Contents

Page 3: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 3

Statistical Software – why??

Solution is Statistical software!!

Manual computation is error prone and time consuming

Clinical trials produces huge volume of data

Page 4: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 4

Statistical Software

Page 5: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 5

SAS – why??

Advanced statistical analysis is much more accessible

Non standard analyses can be programmed

Comparatively faster when working with very large dataset.

Better reporting tool

Also offers data warehousing capability

Popularity

Page 6: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 6

History

• Statistical Analysis System

• Developed by Jim Goodnight and John Shall in1970 at N.C. University

• Initially Developed for Agricultural Research

• SAS Institute founded in 1976

• 98 of world’s top 100 company in Fortune 500 use SAS

• CFR part 11 compliant

Page 7: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 7

SAS solutions for life sciences

SAS for Clinical Data Integration

SAS for Life Sci. Sales & Marketing

SAS Drug Development

SAS Patient Safety

Page 8: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 8

What is SAS ??

Tool for Stat. Analyses

Reporting tool

Programming Language

Data Warehouse

Database

Page 9: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 9

SAS as a Data Warehouse

Page 10: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 10

SAS as a Database

Import/ Export facilities – Can read or export data from a variety of formats

Performing query, merging or data manipulation is possible

Data transformation, derivation of new variables

Page 11: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 11

SAS as a Programming Language

Macro facility

Matrix manipulation

Possible to write routines for new methods

Page 12: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 12

SAS for Statistical Analyses

Descriptive statistics

Contingency Tables

Correlation / Regression

t-test

Wilcoxon test

General Linear Model (ANOVA, ANCOVA)

Logistic regression

Chi-square/ Fisher’s exact test

Trend test

Dunnett Multiple comparison

Logrank test/ Kaplan Meier

Page 13: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 13

SAS as a Reporting Tool

Almost any kind of tables for CSR can be programmed that meets the Clinician’s and Regulatory requirement.

Reporting procedures in SAS

PROC REPORTPROC PRINTPROC TABULATEDATA STEP

Page 14: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM

Learning SAS!!

Page 15: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 15

• Editor • Log• Output• Result• Explorer• Graph

SAS Windows

Page 16: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 16

EDITORTo write/ modify SAS program code

LOG • To check execution of the program.• Helps in identify the error in SAS code

• Tells about details such as amount of time it taken to execute the code

EXPLORER

It displays the list of libraries (containing dataset, formats, compiled macros and graphs)

Page 17: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 17

OUTPUT

It displays the output generated upon execution of SAS code

RESULTS

It displays index of the output

Page 18: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 18

Libraries & Datasets SAS stores Datasets in Libraries.

Libraries are just a referred location in Hard-drive. (e.g., “F:\MADANKU\Ragacin\”)

Datasets in Libraries can be generated using Data steps.

Can be imported from other formats (e.g., Excel, Oracle Clinical etc.)

Page 19: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 19

Procedures in SAS SAS procedures analyze data in SAS data sets

to produce summary statistics to produce tables, listings & graphs to perform SQL queries to perform Statistical analyses to manage and print SAS files.

SAS Procedures come in modules (e.g., SAS/BASE, SAS/STAT, SAS/SQL, SAS/IML, SAS/GRAPH)

Commonly used procedures:

PROC PRINT PROC REPORT PROC UNIVARIATE

PROC MEANS PROC MIXED PROC LOGISTIC

PROC TTEST PROC NLIN PROC GPLOT

PROC FREQ PROC SQL PROC IML

Page 20: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 20

Example (Canada Guieline, 1992)Subject Sequence Treatment Period AuCt ln(AUCt)

A TR T 1 365 5.89990

B RT T 2 405 6.00389

C RT T 2 703 6.55536

E TR T 1 233 5.45104

F RT T 2 247 5.50939

G TR T 1 178 5.18178

H RT T 2 246 5.50533

I TR T 1 408 6.01127

K RT T 2 315 5.75257

L TR T 1 140 4.94164

M TR T 1 165 5.10595

N RT T 2 88 4.47734

O RT T 2 183 5.20949

P TR T 1 122 4.80402

Q RT T 2 68 4.21951

R TR T 1 275 5.61677

Page 21: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 21

Subject Sequence Treatment Period AuCt ln(AUCt)

A TR R 2 375 5.92693

B RT R 1 595 6.38856

C RT R 1 471 6.15486

E TR R 2 190 5.24702

F RT R 1 257 5.54908

G TR R 2 175 5.16479

H RT R 1 382 5.94542

I TR R 2 361 5.88888

K RT R 1 218 5.38450

L TR R 2 92 4.52179

M TR R 2 269 5.59471

N RT R 1 106 4.66344

O RT R 1 290 5.66988

P TR R 2 230 5.43808

Q RT R 1 144 4.96981

R TR R 2 344 5.84064

Example (Canada Guideline, 1992)

Page 22: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 22

Procedures in SAS

Page 23: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 23

Type 3 Tests of Fixed Effects

Effect Num DF Den DF F Value Pr > F

Sequence 1 14 0.09 0.7675

Period 1 14 0.33 0.5734

Treatment 1 14 1.89 0.1909

Estimates

Label Estimate Standard Error DF t Value Pr > |t| Alpha Lower Upper

T VS R -0.1314 0.09563 14 -1.37 0.1909 0.1 -0.2999 0.03699

LabelAUCt Ratio

(T/R)Lower Limit of

AUCt RatioUpper Limit of

AUCt Ratio

T VS R 87.68% 74.09% 103.77%

MACRMACR

Procedures in SAS

Page 24: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 24

Macros in SAS

Collection of SAS statements which can be used repeatedly

Why macro?

- Same program can be used repetitively

- Makes program simpler

- Data driven programs can be made, letting SAS decide what to do based on actual data values

Macros are complicated, but makes the work lot easier

Page 25: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 25

Macros in SAS

Defining of a macro

Calling of a macro

Specifying the analysis, algorithm etc.

Name of the macro

Key-parameter

Page 26: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 26

SAS in CDM Clinical Trial of all phases

- Sample size estimation- Randomization schedule- Tables, Listings & Figures (TLFs)

Pre-clinical Data Analyses

Pharmacovigilance signal generation

Pharmacokinetic (PK) analyses

Pharmacodynamic (PD) analyses

Non-standard- Repeated Measure- Nonlinear Mixed Model- Bayesian

Page 27: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 27

In-house Developed Macro

Pre-clinical Data Analyses

Pharmacovigilance

Sample Size

Randomization Schedule

Page 28: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 28

Page 29: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 29

Body weight – Change and % change

Clinical Chemistry parameters (n=20)

Hematology parameters (n=21)

Urine parameters (n=4)

Organ weights (n=8-9)- Absolute- Relative to body weight- Relative to brain weight

Parameters

Analysis is done for both Main and Recovery part of the study

For male and female separately

Page 30: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 30

Flow of Stat Analyses

Verifying Normality Assumption

• ANCOVA • Dunnett pair-wise

comparison

• K-W test• Wilcoxon pair-wise

comparison

• Log transform• Inverse transform• Square root

Norm

al

Non N

ormal

Page 31: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 31

Page 32: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 32

Process flow

Excel data

SAS data Tables and

graphs

%normtest%toxico%toxico_comb%toxico_rec

Page 33: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 33

Page 34: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 34

Haematology of M ale - I: M ean Platelet Volume (micro-meter cube) : Day29

Krishna M ohan, 12M A Y 09 09:09 Output: F:\KRISHN A M O\S tudy\Toxicolog y\GTF-069-08 \Output\tab5_1.rtf

Vehicle control 30 mg /kg 60 mg /kg 120 mg /kg

7.0

7.5

8 .0

8 .5

9.0

9.5

Mea

n Pl

atel

et V

olum

e (m

icro

-met

er c

ube)

Dose

N 9.00

Page 35: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 35

Page 36: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 36

NProportional Reporting RatioRelative Reporting RationChi- square

Stat task…

Page 37: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 37

Process flow

Excel data

SAS data Tables and

graphs

SAS programs

Page 38: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 38

Page 39: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 39

Page 40: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 40

Page 41: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 41

Validation

Program validation

Dataset validation

Output validation

Macro validation

Page 42: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 42

Program Validation

“Documented evidence that program performs as expected”

Log inspection Log enhancement Intermediate results checking Style

SimplicityReadability (use of comments)Re-usability

Syntax checkingLogical Dead endsInfinite loopsCode never executed

Page 43: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 43

Program Validation

“Documented evidence that program performs as expected”

Log inspection Log enhancement Intermediate results checking Style

SimplicityReadability (use of comments)Re-usability

Syntax checkingLogical Dead endsInfinite loopsCode never executed

“Act in haste and repent in leisure, Code too soon and debug forever”

- Raymond Kennington

Page 44: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 44

Program Validation

Cross verification with requirement/ algorithm Documentation (History and Version)

Page 45: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 45

Output Validation

Matching of exact values Layout Format of the values Consistency with the SOPs/ SAP/ Specification

document

Page 46: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 46

SAS Macro ValidationWhite Box testing

- Takes account internal mechanism of macro

- Testing with known, provided data and known results

- Check for the correct results

- Only legal parameters should be specified for its arguments

Black Box testing

- Ignores the internal mechanism of macro

- Testing with unknown data and unknown results

- Check for plausible results

- Any kind of parameters should be specified for its arguments

- Focuses only on the output

Page 47: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 47

ComplianceSAS System Installation Mgt.

- All installations are documented to the <SASROOT>\core\sasinst\hotfix directory

- Testing of installation done by SAS Institute supplied installation test kit located in <SASROOT>\core\sastest.

Version Control

- Important for a regulated environment to track changes in program file, log file and output file.

- SAS does not provide these feature.

- It can be attained through use of version control packages such as Microsoft Visual SourceSafe.

Page 48: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 48

Compliance

Security of SAS Datasets

- Controlled access to the contents of SAS datasets can be administered through password protection of the dataset

Retrieval of Electronic Records- Compliance is straightforward

- Printing audit trails can be done by setting the TYPE option to TYPE=Audit in PROC PRINT

SAS Coexistence with FDA 21 CFR Part 11, How Far Can We Get? – Available at www.lexjansen.com/pharmasug/2002/proceed/fdacomp/fda05.pdf

Audit Trails for SAS Datasets - With PROC DATASETS, it is possible to initiate

SAS dataset specific audit trails, that log dataset updates, modification and deletions.

Page 49: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 49

SAS for CDISC

Data standards are critical component in quest to improve global public health.

Varying data standards

CDISC attempts to define an industry standard for clinical data formatting

SDTM, ODM, LAB and ADaM can be effectively implemented in SAS Drug Development

ODM SDTM

PROC CDISC

SAS XML LIBNAME ENGINE

SAS Dataset

Page 50: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 50

Data Flow in e-Submission

Page 51: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 51

Any Questions

Page 52: CDM 1 SAS in Pharmaceutical Industry 30 July 2009 Arjun Roy & Madan Gopal Kundu Clinical Data Management & Biostatistics MACR.

CDMCDM 52

Thank You…!