SAS
explore your knowledge
SAS
Clinical Research & Clinical Data Management:
Introduction to Clinical Research and Clinical Data Management
Introduction to Oracle Clinical Database
Different Phases of clinical trials
INDA, NDA, ANDA Applications
ICH-GCP Guidelines
Responsibilities of Clinical Trial Team
Protocol and Informed Consent Forms
Roles and Responsibilities of CDM Team
CDM Functions
Clinical Data Management Process and Life cycle
Data Management Plan and Process
Electronic Record and Signatures - 21 CFR Part 11
Case Report Forms, Types of CRFs
Designing of CRFs
CRF Annotation and FDA guidelines
Data Capture Methods and EDC
Data Entry – First pass and Second Pass Entry
Edit Check Specifications
Data Validation Procedures
Discrepancy Management
Data Clarification Forms (DCFs)
Database Locking and Freezing
Data Storage & Archival
Data Coding and Medical Dictionaries
SAE Reconciliation
Quality Assurance & Quality Control
Auditing
CDISC Standards and guidelines
Oracle Clinical Database
Introduction to OC window
Subsystems in OC
Defining Programs and Projects
Defining Organization Units
Defining Regions
Defining Planned Studies
Easy Study Design
Creating Intervals
Creating Events
Creating treatment patterns
Creating Investigator, Site Records and Assignments
Creating Patient Positions and Assignments
Creating Questions
Creating Question Groups
Creating and Maintaining DVG's
Copy Groups
Creating DCM's, DCI's & DCI Books
Validation Procedures
Derivation Procedures
Test a Study
Test Data Entry
Initial Login
Key Changes
First Pass Entry
Second Pass Entry
Comparison Reconciliation
Update
Browse
Patient Enrollment
Missing DCMs
Data Validation(Batch validation)
Discrepancy Management
Data Clarification Forms (DCFs)
Data Extract and SAS Extract
Making Mass Changes
Locking and Freezing
Lab Subsystem
RDC (Remote Data Capture):
Data entry in RDC
Discrepancy Management in RDC
CRFs in RDC
Clinical Development process
Different phases of Clinical Trials
CRO and Clinical Research Team
Case Report Forms
Data Coding
IB, Protocol and Informed consent form
History and overview of Pharmacovigilance
Regulatory Authorities
Pharmacovigilance in India
Spontaneous reporting
Active pharmacovigilance
Adverse Events and its types
Drug Safety in clinical trials and post marketed drugs
Different sources of Adverse Events reporting
Different types of AE Reporting Forms
Expedited reporting and its timelines
Aggregate reporting
Different departments working on Pharmacovigilance
Four factors for the reportable case
Causality assessment of the adverse event
MedDRA and WHODD coding
SAE narrative writing
PSUR and its submission timelines
Practical Hands-on Training on Oracle Argus Safety Database Argus Console
PV Overview
PV Business process
Introduction to Oracle Argus Safety Database
Family, Product and License creation
Clinical Study configuration
Sites, users and Groups creation
Workflow Configuration
Case priority Configuration
Case Numbering
Field Validation
Code list Configuration
Argus Safety
Different icons used during the case processing and their purpose.
Different tabs used in case processing
Case Bookin and Data entry
Case Processing
Case Routing Based on workflow
Case Quality check, Medical review
Duplicate case check or verification
Report Generation for Regulatory Submission
Expedited Reports and Aggregate Reports
Case Bookin in LAM and Routing to Central Safety database
MedDRA coding and WHO DD coding
Narrative Writing
1: INTRODUCTION TO SAS
INTRODUCTION
NEED FOR SAS
WHO USES SAS
WHAT IS SAS?
OVERVIEW OF BASE SAS SOFTWARE
DATA MANAGEMENT FACILITY
STRUCTURE OF SAS DATASET
SAS PROGRAM
PROGRAMMING LANGUAGE
ELEMENTS OF THE SAS LANGUAGE
RULES FOR SAS STATEMENTS
RULES FOR MOST SAS NAMES
SPECIAL RULES FOR VARIABLE NAMES
TYPES OF VARIABLES
DATA ANALYSIS AND REPORTING UTILITIES
TRADITIONAL OUTPUT
WAYS TO RUN SAS PROGRAMS
SAS WINDOWING ENVIRONMENT
NONINTERACTIVE MODE
BATCH MODE
INTERACTIVE LINE MODE
RUNNING PROGRAMS IN THE SAS WINDOWING ENVIRONMENT
2: HOW SAS WORKS
WRITING YOUR FIRST SAS PROGRAM
A SIMPLE PROGRAM TO READ RAW DATA AND PRODUCE A REPORT
ENHANCING THE PROGRAM
MORE ON COMMENT STATEMENTS
INTERNAL PROCESSING IN SAS
HOW SAS WORKS
THE COMPILATION PHASE
THE EXECUTION PHASE
PROCESSING A DATA STEP: A WALKTHROUGH
CREATING THE INPUT BUFFER AND THE PROGRAM DATA VECTOR
WRITING AN OBSERVATION TO THE SAS DATA SET
FOUR TYPES OF SAS LIBRARIES
SAS LIBRARIES
WORK LIBRARY
SASHELP LIBRARY
SASUSER LIBRARY
3: READING RAW DATA INTO SAS
WHAT IS RAW DATA
DEFINITIONS
DATA VALUES
NUMERIC VALUE
CHARACTER VALUE
STANDARD DATA
NONSTANDARD DATA
NUMERIC DATA
CHARACTER DATA
CHOOSING AN INPUT STYLE
LIST INPUT
MODIFIED LIST INPUT
COLUMN INPUT
FORMATTED INPUT
NAMED INPUT
INSTREAM DATA
CREATING MULTIPLE RECORDS FROM SINGLE INPUT ROW
READING DATA FROM EXTERNAL FILES
READING BLANK SEPARATED VALUES (LIST OR FREE FORM DATA):
READING RAW DATA SEPARATED BY COMMAS (.CSV FILES):
READING IN RAW DATA SEPARATED BY TABS (.TXT FILES):
USING INFORMATS WITH LIST INPUT
SUPPLYING AN INFORMAT STATEMENT WITH LIST INPUT
USING LIST INPUT WITH EMBEDDED DELIMITERS
READING RAW DATA THAT ARE ALIGNED IN COLUMNS:
METHOD 1: COLUMN INPUT
METHOD 2: FORMATTED INPUT
USING MORE THAN ONE INPUT STATEMENT: THE SINGLE TRAILING @
READING COLUMN DATA THAT IS ON MORE THAN ONE LINE
MIXED-STYLE INPUT:
INFILE OPTIONS FOR SPECIAL SITUATIONS
FLOWOVER
MISSOVER
TRUNCOVER
PAD
USING LRECL TO READ VERY LONG LINES OF RAW DATA
CHECKING YOUR DATA AFTER IT HAS BEEN READ INTO SAS
4: READING DATA FROM A DATASET
INTRODUCTION
SET STATEMENT OVERVIEW
AUTOMATIC VARIABLES IN SAS
INTERLEAVE MULTIPLE SAS DATA SETS
COMBINE MULTIPLE SAS DATA SETS
CREATING & MODIFYING VARIABLES
CREATING MULTIPLE DATASETS IN A SINGLE DATA-STEP
SUBSETTING OBSERVATIONS
CONDITIONAL SAS STATEMENTS
LOGICAL AND SPECIAL OPERATORS
THE SAS SUPERVISOR AND THE SET STATEMENT
EFFICIENCY AND THE SET STATEMENT
KNOW YOUR DATA
SET STATEMENT DATA SET OPTIONS
DROP AND KEEP OPTIONS
RENAME OPTION
FIRSTOBS AND OBS OPTIONS
IN OPTION -
WHERE OPTION -
OTHER SET STATEMENT OPTIONS
END OPTION
KEY OPTION
NOBS OPTION
POINT OPTION
DO LOOPS AND THE SET STATEMENT
INTRODUCTION TO RETAIN STATEMENT
CARRY OVER VALUES FROM ONE OBSERVATION TO ANOTHER
COMPARE VALUES ACROSS OBSERVATIONS
ASSIGN INITIAL VALUES
DETERMINING COLUMN ORDER IN OUTPUT DATASET
SAS SYSTEM OPTIONS
5: READING DATA FROM A DATASET
INPUT SAS DATA SET FOR EXAMPLE
SELECTING OBSERVATIONS FOR A NEW SAS DATA SET
DELETING OBSERVATIONS BASED ON A CONDITION
ACCEPTING OBSERVATIONS BASED ON A CONDITION
COMPARING THE DELETE AND SUBSETTING IF STATEMENTS
METHODS OF CREATING NEW DATA SETS WITH A SUBSET
SUBSETTING RECORDS FROM AN EXTERNAL FILE WITH A SUBSETTING IF STATEMENT
SUBSETTING OBSERVATIONS IN A DATA STEP WITH A WHERE STATEMENT
SUBSETTING OBSERVATIONS IN A PROC STEP WITH A WHERE STATEMENT
SUBSETTING OBSERVATIONS IN PROC SQL
DIFFERENCE BETWEEN IF AND WHERE
6: SAS INFORMATS AND FORMATS
OVERVIEW
USING SAS INFORMATS
INPUT STATEMENT
INPUT FUNCTION
INPUTN AND INPUTC FUNCTIONS
ATTRIB AND INFORMAT STATEMENTS
USING SAS FORMATS
FORMAT STATEMENT IN PROCEDURES
PUT STATEMENT
PUT FUNCTION
PUTN AND PUTC FUNCTIONS
BESTw. Format
ADDITIONAL COMMENTS
7: SAS FUNCTIONS
CATEGORIES OF FUNCTIONS
SAS CHARACTER FUNCTIONS
FUNCTIONS THAT CHANGE THE CASE OF CHARACTERS
UPCASE
LOWCASE
PROPCASE
FUNCTIONS THAT REMOVE CHARACTERS FROM STRINGS
FUNCTION: COMPBL
FUNCTION: COMPRESS
FUNCTIONS THAT SEARCH FOR CHARACTERS
FUNCTION: ANYALNUM
FUNCTION: ANYALPHA
FUNCTION: ANYDIGIT
FUNCTION: ANYPUNCT
FUNCTION: ANYSPACE
FUNCTION: NOTALNUM
FUNCTION: NOTALPHA
FUNCTION: NOTDIGIT
FUNCTION: NOTUPPER
FUNCTIONS THAT SEARCH STRINGS
FIND AND FINDC
INDEX, INDEXC, AND INDEXW
FUNCTIONS TO VERIFY DATA
FUNCTION VERIFY
FUNCTIONS THAT EXTRACT PARTS OF STRINGS
FUNCTION: SUBSTR (ON THE LEFT-HAND SIDE OF THE EQUAL SIGN)
FUNCTION: SUBSTRN
FUNCTIONS THAT JOIN TWO OR MORE STRINGS TOGETHER
FUNCTION: CAT
FUNCTION: CATS
FUNCTION: CATT
FUNCTION: CATX
FUNCTIONS THAT REMOVE BLANKS FROM STRINGS
FUNCTION: LEFT
FUNCTION: TRIM
FUNCTION: TRIMN
FUNCTION: STRIP
FUNCTIONS THAT COMPARE STRINGS
FUNCTION: COMPARE
FUNCTIONS THAT DIVIDE STRINGS INTO "WORDS"
FUNCTION: SCAN
FUNCTION: SCANQ
FUNCTIONS THAT SUBSTITUTE LETTERS OR WORDS IN STRINGS
FUNCTION: TRANSLATE
FUNCTION: TRANWRD
FUNCTIONS THAT COMPUTE THE LENGTH OF STRINGS
FUNCTION: LENGTH
FUNCTION: LENGTHC
FUNCTION: LENGTHM
FUNCTION: LENGTHN
FUNCTIONS THAT COUNT THE NUMBER OF LETTERS OR SUBSTRINGS IN A STRING
FUNCTION: COUNT
FUNCTION: COUNTC
MISCELLANEOUS STRING FUNCTIONS
FUNCTION: MISSING
FUNCTION: REPEAT
FUNCTION: REVERSE
SAS DATE AND TIME FUNCTIONS
INTRODUCTION
WHAT IS A SAS DATE AND TIME LITERAL?
DATE AND TIME FUNCTIONS
FUNCTINS TO CREATE DATE AND TIME VALUES
FUNCTIONS TO TAKIE DATETIME VALUES APART
FUNCTIONS TO GET QUARTER ,YEAR OR DAY OF THE DATE
FUNCTIONS THAT WORK WITH INTERVALS
USING FORMATS FOR DATE AND TIME
SYSTEM OPTIONS FORDATE AND TIME
8: AN INTRODUCTION TO ARRAYS AND ARRAY PROCESSING
WHY DO WE NEED ARRAYS?
BASIC ARRAY CONCEPTS
ARRAY STATEMENT
ARRAY REFERENCES
VARIABLE NAME ARRAY REFERENCE
USING ARRAY INDEXES
ONE DIMENSION ARRAYS
MULTI-DIMENSION ARRAYS
TEMPORARY ARRAYS
SORTING ARRAYS
Determining Array Bounds: LBOUND and HBOUND Functions
WHEN TO USE ARRAYS
COMMON ERRORS AND MISUNDERSTANDINGS
INVALID INDEX RANGE
FUNCTION NAME AS AN ARRAY NAME
ARRAY REFERENCED IN MULTIPLE DATA STEPS, BUT DEFINED IN ONLY ONE
9: BY - GROUP PROCESSING
DEFINITIONS FOR BY-GROUP PROCESSING
BY-GROUP PROCESSING
BY VALUE
BY GROUP
FIRST.VARIABLE AND LAST.VARIABLE
MODIFYING SAS DATA SETS: EXAMPLES.
INVOKING BY-GROUP PROCESSING
PREPROCESSING INPUT DATA FOR BY-GROUP PROCESSING
SORTING OBSERVATIONS FOR BY-GROUP PROCESSING
INDEXING FOR BY-GROUP PROCESSING
HOW THE DATA STEP IDENTIFIES BY GROUPS
PROCESSING OBSERVATIONS IN A BY GROUP
HOW SAS DETERMINES FIRST.VARIABLE AND LAST.VARIABLE
PROCESSING BY-GROUPS IN THE DATA STEP
OVERVIEW
PROCESSING BY-GROUPS CONDITIONALLY
DATA NOT IN ALPHABETIC OR NUMERIC ORDER
DATA GROUPED BY FORMATTED VALUES
10: OVERVIEW OF METHODS FOR COMBINING SAS DATA SETS
DEFINITIONS
CONCATENATING
INTERLEAVING
ONE-TO- ONE READING OR ONE-TO-ONE MERGING
MATCH-MERGING
UPDATING
MODIFYING
DEFINITIONS FOR READING, COMBINING, AND MODIFYING SAS DATA SETS
READING A SAS DATA SET
COMBINING SAS DATA SETS
MODIFYING SAS DATA SETS
OVERVIEW OF TOOLS
READING SAS DATA SETS
READING A SINGLE SAS DATA SET
READING FROM MULTIPLE SAS DATA SETS
COMBINING SAS DATA SETS: BASIC CONCEPTS
ONE-TO-ONE
ONE-TO-MANY AND MANY-TO-ONE
MANY-TO-MANY
ACCESS METHODS: SEQUENTIAL VERSUS DIRECT
SEQUENTIAL ACCESS
DIRECT ACCESS
ONE-TO-ONE READING
DATA STEP PROCESSING DURING A ONE-TO-ONE READING
ONE-TO-ONE MERGING
MATCH-MERGING
UPDATING WITH THE UPDATE AND THE MODIFY STATEMENTS :
DEFINITIONS
SYNTAX OF THE UPDATE STATEMENT
SYNTAX OF THE MODIFY STATEMENT -
UPDATING WITH NONMATCHED OBSERVATIONS, MISSING VALUES, AND NEW VARIABLES -
USING AN INDEX WITH THE MODIFY STATEMENT
11: SAS PROCEDURES
INTRODUCTION
THE ANATOMY OF A PROC
THE PROC STATEMENT
TITLE AND FOOTNOTE STATEMENTS
BY STATEMENT
LABEL STATEMENT
FORMAT STATEMENT
RUN OR QUIT STATEMENT
DESCRIPTION OF DATA USED IN REPORTS
SAS REPORTING PROCEDURES
PROCS FOR ALL THAT DETAIL
USING PROC PRINT
USING PROC SQL
PROC REPORT
PROCS THAT SUMMARIZE
USING PROC CHART
USING PROC FREQ
USING PROC MEANS
USING PROC UNIVARIATE
INTRODUCTION TO PROC TABULATE
DATA MANIPULATION AND MANAGEMENT PROCEDURE
PROC SORT
PROC DATASETS
PROC FORMAT
PROC CONTENTS
OTHER IMPORTANT PROCS
PROC TRANSPOSE
DEFINITIONS
PROC PRINTTO
COMPARE PROCEDURE
PROC APPEND
HOW TO IMPORT AN EXCEL FILE INTO SAS
12: THE OUTPUT DELIVERY SYSTEM (ODS)
INTRODUCTION
CREATING VARIOUS TYPES OF REPORTS LISTING OUTPUT
OTHER DESTINATIONS
HTML
PDF AND POSTSCRIPT
RTF FILES
MICROSOFT EXCEL
ADDING STYLE TO YOUR REPORTS
LOCATE EXISTING STYLES
ODS STYLE= OPTION
CUSTOMIZE YOUR REPORTS
ODS SELECT; AND ODS EXCLUDE;
OTHER CUSTOMIZATIONS
ODS PROCLABEL= ;
ODS PROCTITLE; AND ODS NOPROCTITLE;
ADVANCED TECHNIQUES
ODS DOCUMENT
PROC TEMPLATE
"Reviewing the Platform for SAS Business Analytics"
Exploring the platform for SAS
Business Analytics overview
Exploring the client tier, middle tier, server tier, and data tier
Administering the SAS Environment
Overview of administration tasks
Determining the State of the SAS Environment
Checking the state of SAS servers
Exploring the metadata server and repositories
Troubleshooting the metadata server
Monitoring, Logging, and Troubleshooting SAS Servers
Identifying different types of SAS servers
Monitoring SAS servers and spawners
Logging SAS servers and spawners
Troubleshooting SAS servers
Backing Up the SAS Environment
Backing up metadata with the Backup Wizard
Exploring OMABAKUP
Scheduling backups
Backing up physical files
Administering Client Applications
Exploring connection profiles
Using roles to control access to application
Functionality
Exploring SAS folders
Administering Users
Defining regular users and groups
Defining administrative users
Giving users access to servers
Administering Data Access
Registering libraries
Tables in the metadata
Updating table metadata
Pre-assigning libraries
Troubleshooting data access
Securing Metadata
Introduction to metadata security
Exploring metadata permission
Exploring predefined ACTs
Securing content in the folder tree
Securing content outside the folder tree
Creating additional ACTs
Moving Metadata
Replicating an entire repository
Promoting selected content
Updating the SAS Environment
Applying hot fixes to the SAS environment
SAS Enterprise Guide
Introduction on SAS EG Application
Customizing SAS Enterprise Guide options
Setting up and managing profiles
Importing files from sources other than SAS
Accessing data via SAS libraries
Grouping and summarizing data
Introduction to querying data
Filtering and sorting data
Creating new columns with an expression
Joining tables
Grouping and summarizing data in a query (self-study)
Creating new columns by recoding values (self-study)
Creating a frequency report
Generating HTML, PDF, and RTF output
Creating a listing report
Creating a graph
Creating Stored Process from SAS EG.
Creating OLAP cubes from SAS EG.
Working on different STATASTICAL Procedures.
SAS/DI Studio Or ETL Studio
Data ware housing Concept
Exploring SAS Data Integration Studio
Working on Change Management
Explaining how to define source, target data structures and designing jobs.
Introduction to jobs and the job editor
Working with propagation and mappings
Working with intermediate files
Data Transformations
Proc SQL
Lookup Table
Append
Extract
Validate
Return Code Check
Data Transfer
Sort
Rank
Splitter
Control Table
User Written Code
Create Transformation Template
Transpose
Data Access Transformations
File Reader
File Writer
Table Loader
Analysis Transformations
Frequency Report
One-Way Frequency Report
Summary Report
Tabulate Report
Print Report
Standardize
SAS OLAP Cube Studio
o  LAP Introduction
Discuss Dimensions / Facts / Hierarchies / Levels / Measures / Ragged Hierarchies / Aggregation
Create an OLAP Cube from Detail Table (ROLAP)
Create an OLAP Cube from Star Schema (ROLAP, HOLAP)
Create an OLAP Cube from Summarized Table
Create an OLAP * Cube with the following features:
o  Dimensions * Levels * Hierarchies* Measures * Aggregates
Review the Cube design and structure
Exploring OLAP * Cube with
o  SAS Enterprise Guide
o  SAS Information Map Studio
o  Microsoft Office Excel
o  SAS Web Report Studio
SAS Information Map Studio
Introduction to SAS information Map Studio.
Updating an information map with filters, folders, and data items
Adding additional data sources to an information map
o  verview of information map pre-filters
Building a general pre-filter
Building an authorization-based pre-filter
Information Maps and Stored Process.
o  verview of stored processes
Associating stored processes with an information map
Using information maps in SAS Web Report Studio
o  verview of surfacing data with information maps
Using information maps in the SAS Information Delivery Portal
Using information maps in SAS Enterprise Guide
Using information maps in the SAS Add-In For Microsoft Office
o  verview of OLAP cubes
Building an information map for an OLAP cube
SAS Web Report Studio
Introduction on SAS Web Report Studio
Calling Information Maps into WRS.
Creating filters at WRS
Creating Layouts for Reports.
Creating Prompts.
Customizable roles to authorize capabilities(From SMC)
Working on Report Creation and Templates.
SAS Information Delivery Portal
Introduction to SAS IDP
Adding a Portal page
Adding Contents to Portlet.
Adding portlets to page
Utilize SAS EG to create content and publish packages to the framework
Viewing and managing portal content.
Portal Customization
Call Reports from WRS to IDP.
BASE SAS
1: INTRODUCTION TO SAS
INTRODUCTION
NEED FOR SAS
WHO USES SAS
WHAT IS SAS?
OVERVIEW OF BASE SAS SOFTWARE
DATA MANAGEMENT FACILITY
STRUCTURE OF SAS DATASET
SAS PROGRAM
PROGRAMMING LANGUAGE
ELEMENTS OF THE SAS LANGUAGE
RULES FOR SAS STATEMENTS
RULES FOR MOST SAS NAMES
SPECIAL RULES FOR VARIABLE NAMES
TYPES OF VARIABLES
DATA ANALYSIS AND REPORTING UTILITIES
TRADITIONAL OUTPUT
WAYS TO RUN SAS PROGRAMS
SAS WINDOWING ENVIRONMENT
NONINTERACTIVE MODE
BATCH MODE
INTERACTIVE LINE MODE
RUNNING PROGRAMS IN THE SAS WINDOWING ENVIRONMENT
2: HOW SAS WORKS
WRITING YOUR FIRST SAS PROGRAM
A SIMPLE PROGRAM TO READ RAW DATA AND PRODUCE A REPORT
ENHANCING THE PROGRAM
MORE ON COMMENT STATEMENTS
INTERNAL PROCESSING IN SAS
HOW SAS WORKS
THE COMPILATION PHASE
THE EXECUTION PHASE
PROCESSING A DATA STEP: A WALKTHROUGH
CREATING THE INPUT BUFFER AND THE PROGRAM DATA VECTOR
WRITING AN OBSERVATION TO THE SAS DATA SET
FOUR TYPES OF SAS LIBRARIES
SAS LIBRARIES
WORK LIBRARY
SASHELP LIBRARY
SASUSER LIBRARY
3: READING RAW DATA INTO SAS
WHAT IS RAW DATA
DEFINITIONS
DATA VALUES
NUMERIC VALUE
CHARACTER VALUE
STANDARD DATA
NONSTANDARD DATA
NUMERIC DATA
CHARACTER DATA
CHOOSING AN INPUT STYLE
LIST INPUT
MODIFIED LIST INPUT
COLUMN INPUT
FORMATTED INPUT
NAMED INPUT
INSTREAM DATA
CREATING MULTIPLE RECORDS FROM SINGLE INPUT ROW
READING DATA FROM EXTERNAL FILES
READING BLANK SEPARATED VALUES (LIST OR FREE FORM DATA):
READING RAW DATA SEPARATED BY COMMAS (.CSV FILES):
READING IN RAW DATA SEPARATED BY TABS (.TXT FILES):
USING INFORMATS WITH LIST INPUT
SUPPLYING AN INFORMAT STATEMENT WITH LIST INPUT
USING LIST INPUT WITH EMBEDDED DELIMITERS
READING RAW DATA THAT ARE ALIGNED IN COLUMNS:
METHOD 1: COLUMN INPUT
METHOD 2: FORMATTED INPUT
USING MORE THAN ONE INPUT STATEMENT: THE SINGLE TRAILING @
READING COLUMN DATA THAT IS ON MORE THAN ONE LINE
MIXED-STYLE INPUT:
INFILE OPTIONS FOR SPECIAL SITUATIONS
FLOWOVER
MISSOVER
TRUNCOVER
PAD
USING LRECL TO READ VERY LONG LINES OF RAW DATA
CHECKING YOUR DATA AFTER IT HAS BEEN READ INTO SAS
4: READING DATA FROM A DATASET
INTRODUCTION
SET STATEMENT OVERVIEW
AUTOMATIC VARIABLES IN SAS
INTERLEAVE MULTIPLE SAS DATA SETS
COMBINE MULTIPLE SAS DATA SETS
CREATING & MODIFYING VARIABLES
CREATING MULTIPLE DATASETS IN A SINGLE DATA-STEP
SUBSETTING OBSERVATIONS
CONDITIONAL SAS STATEMENTS
LOGICAL AND SPECIAL OPERATORS
THE SAS SUPERVISOR AND THE SET STATEMENT
EFFICIENCY AND THE SET STATEMENT
KNOW YOUR DATA
SET STATEMENT DATA SET OPTIONS
DROP AND KEEP OPTIONS
RENAME OPTION
FIRSTOBS AND OBS OPTIONS
IN OPTION -
WHERE OPTION -
OTHER SET STATEMENT OPTIONS
END OPTION
KEY OPTION
NOBS OPTION
POINT OPTION
DO LOOPS AND THE SET STATEMENT
INTRODUCTION TO RETAIN STATEMENT
CARRY OVER VALUES FROM ONE OBSERVATION TO ANOTHER
COMPARE VALUES ACROSS OBSERVATIONS
ASSIGN INITIAL VALUES
DETERMINING COLUMN ORDER IN OUTPUT DATASET
SAS SYSTEM OPTIONS
5: READING DATA FROM A DATASET
INPUT SAS DATA SET FOR EXAMPLE
SELECTING OBSERVATIONS FOR A NEW SAS DATA SET
DELETING OBSERVATIONS BASED ON A CONDITION
ACCEPTING OBSERVATIONS BASED ON A CONDITION
COMPARING THE DELETE AND SUBSETTING IF STATEMENTS
METHODS OF CREATING NEW DATA SETS WITH A SUBSET
SUBSETTING RECORDS FROM AN EXTERNAL FILE WITH A SUBSETTING IF STATEMENT
SUBSETTING OBSERVATIONS IN A DATA STEP WITH A WHERE STATEMENT
SUBSETTING OBSERVATIONS IN A PROC STEP WITH A WHERE STATEMENT
SUBSETTING OBSERVATIONS IN PROC SQL
DIFFERENCE BETWEEN IF AND WHERE
6: SAS INFORMATS AND FORMATS
OVERVIEW
USING SAS INFORMATS
INPUT STATEMENT
INPUT FUNCTION
INPUTN AND INPUTC FUNCTIONS
ATTRIB AND INFORMAT STATEMENTS
USING SAS FORMATS
FORMAT STATEMENT IN PROCEDURES
PUT STATEMENT
PUT FUNCTION
PUTN AND PUTC FUNCTIONS
BESTw. Format
ADDITIONAL COMMENTS
7: SAS FUNCTIONS
CATEGORIES OF FUNCTIONS
SAS CHARACTER FUNCTIONS
FUNCTIONS THAT CHANGE THE CASE OF CHARACTERS
UPCASE
LOWCASE
PROPCASE
FUNCTIONS THAT REMOVE CHARACTERS FROM STRINGS
FUNCTION: COMPBL
FUNCTION: COMPRESS
FUNCTIONS THAT SEARCH FOR CHARACTERS
FUNCTION: ANYALNUM
FUNCTION: ANYALPHA
FUNCTION: ANYDIGIT
FUNCTION: ANYPUNCT
FUNCTION: ANYSPACE
FUNCTION: NOTALNUM
FUNCTION: NOTALPHA
FUNCTION: NOTDIGIT
FUNCTION: NOTUPPER
FUNCTIONS THAT SEARCH STRINGS
FIND AND FINDC
INDEX, INDEXC, AND INDEXW
FUNCTIONS TO VERIFY DATA
FUNCTION VERIFY
FUNCTIONS THAT EXTRACT PARTS OF STRINGS
FUNCTION: SUBSTR (ON THE LEFT-HAND SIDE OF THE EQUAL SIGN)
FUNCTION: SUBSTRN
FUNCTIONS THAT JOIN TWO OR MORE STRINGS TOGETHER
FUNCTION: CAT
FUNCTION: CATS
FUNCTION: CATT
FUNCTION: CATX
FUNCTIONS THAT REMOVE BLANKS FROM STRINGS
FUNCTION: LEFT
FUNCTION: RIGHT
FUNCTION: TRIM
FUNCTION: TRIMN
FUNCTION: STRIP
FUNCTIONS THAT COMPARE STRINGS
FUNCTION: COMPARE
FUNCTIONS THAT DIVIDE STRINGS INTO "WORDS"
FUNCTION: SCAN
FUNCTION: SCANQ
FUNCTIONS THAT SUBSTITUTE LETTERS OR WORDS IN STRINGS
FUNCTION: TRANSLATE
FUNCTION: TRANWRD
FUNCTIONS THAT COMPUTE THE LENGTH OF STRINGS
FUNCTION: LENGTH
FUNCTION: LENGTHC
FUNCTION: LENGTHM
FUNCTION: LENGTHN
FUNCTIONS THAT COUNT THE NUMBER OF LETTERS OR SUBSTRINGS IN A STRING
FUNCTION: COUNT
FUNCTION: COUNTC
MISCELLANEOUS STRING FUNCTIONS
FUNCTION: MISSING
FUNCTION: REPEAT
FUNCTION: REVERSE
SAS DATE AND TIME FUNCTIONS
INTRODUCTION
WHAT IS A SAS DATE AND TIME LITERAL?
DATE AND TIME FUNCTIONS
FUNCTINS TO CREATE DATE AND TIME VALUES
FUNCTIONS TO TAKIE DATETIME VALUES APART
FUNCTIONS TO GET QUARTER ,YEAR OR DAY OF THE DATE
FUNCTIONS THAT WORK WITH INTERVALS
USING FORMATS FOR DATE AND TIME
SYSTEM OPTIONS FORDATE AND TIME
8: AN INTRODUCTION TO ARRAYS AND ARRAY PROCESSING
WHY DO WE NEED ARRAYS?
BASIC ARRAY CONCEPTS
ARRAY STATEMENT
ARRAY REFERENCES
VARIABLE NAME ARRAY REFERENCE
USING ARRAY INDEXES
ONE DIMENSION ARRAYS
MULTI-DIMENSION ARRAYS
TEMPORARY ARRAYS
SORTING ARRAYS
Determining Array Bounds: LBOUND and HBOUND Functions
WHEN TO USE ARRAYS
COMMON ERRORS AND MISUNDERSTANDINGS
INVALID INDEX RANGE
FUNCTION NAME AS AN ARRAY NAME
ARRAY REFERENCED IN MULTIPLE DATA STEPS, BUT DEFINED IN ONLY ONE
9: BY - GROUP PROCESSING
DEFINITIONS FOR BY-GROUP PROCESSING
BY-GROUP PROCESSING
BY VALUE
BY GROUP
FIRST.VARIABLE AND LAST.VARIABLE
MODIFYING SAS DATA SETS: EXAMPLES.
INVOKING BY-GROUP PROCESSING
PREPROCESSING INPUT DATA FOR BY-GROUP PROCESSING
SORTING OBSERVATIONS FOR BY-GROUP PROCESSING
INDEXING FOR BY-GROUP PROCESSING
HOW THE DATA STEP IDENTIFIES BY GROUPS
PROCESSING OBSERVATIONS IN A BY GROUP
HOW SAS DETERMINES FIRST.VARIABLE AND LAST.VARIABLE
PROCESSING BY-GROUPS IN THE DATA STEP
OVERVIEW
PROCESSING BY-GROUPS CONDITIONALLY
DATA NOT IN ALPHABETIC OR NUMERIC ORDER
DATA GROUPED BY FORMATTED VALUES
10: OVERVIEW OF METHODS FOR COMBINING SAS DATA SETS
DEFINITIONS
CONCATENATING
INTERLEAVING
ONE-TO- ONE READING OR ONE-TO-ONE MERGING
MATCH-MERGING
UPDATING
MODIFYING
DEFINITIONS FOR READING, COMBINING, AND MODIFYING SAS DATA SETS
READING A SAS DATA SET
COMBINING SAS DATA SETS
MODIFYING SAS DATA SETS
OVERVIEW OF TOOLS
READING SAS DATA SETS
READING A SINGLE SAS DATA SET
READING FROM MULTIPLE SAS DATA SETS
COMBINING SAS DATA SETS: BASIC CONCEPTS
ONE-TO-ONE
ONE-TO-MANY AND MANY-TO-ONE
MANY-TO-MANY
ACCESS METHODS: SEQUENTIAL VERSUS DIRECT
SEQUENTIAL ACCESS
DIRECT ACCESS
ONE-TO-ONE READING
DATA STEP PROCESSING DURING A ONE-TO-ONE READING
ONE-TO-ONE MERGING
MATCH-MERGING
UPDATING WITH THE UPDATE AND THE MODIFY STATEMENTS :
DEFINITIONS
SYNTAX OF THE UPDATE STATEMENT
SYNTAX OF THE MODIFY STATEMENT -
UPDATING WITH NONMATCHED OBSERVATIONS, MISSING VALUES, AND NEW VARIABLES -
USING AN INDEX WITH THE MODIFY STATEMENT
11: SAS PROCEDURES
INTRODUCTION
THE ANATOMY OF A PROC
THE PROC STATEMENT
TITLE AND FOOTNOTE STATEMENTS
BY STATEMENT
LABEL STATEMENT
FORMAT STATEMENT
RUN OR QUIT STATEMENT
DESCRIPTION OF DATA USED IN REPORTS
SAS REPORTING PROCEDURES
PROCS FOR ALL THAT DETAIL
USING PROC PRINT
USING PROC SQL
PROC REPORT
PROCS THAT SUMMARIZE
USING PROC CHART
USING PROC FREQ
USING PROC MEANS
USING PROC UNIVARIATE
INTRODUCTION TO PROC TABULATE
DATA MANIPULATION AND MANAGEMENT PROCEDURE
PROC SORT
PROC DATASETS
PROC FORMAT
PROC CONTENTS
OTHER IMPORTANT PROCS
PROC TRANSPOSE
DEFINITIONS
PROC PRINTTO
COMPARE PROCEDURE
PROC APPEND
HOW TO IMPORT AN EXCEL FILE INTO SAS
12: THE OUTPUT DELIVERY SYSTEM (ODS)
INTRODUCTION
CREATING VARIOUS TYPES OF REPORTS LISTING OUTPUT
OTHER DESTINATIONS
HTML
PDF AND POSTSCRIPT
RTF FILES
MICROSOFT EXCEL
ADDING STYLE TO YOUR REPORTS
LOCATE EXISTING STYLES
ODS STYLE= OPTION
CUSTOMIZE YOUR REPORTS
ODS SELECT; AND ODS EXCLUDE;
OTHER CUSTOMIZATIONS
ODS PROCLABEL= ;
ODS PROCTITLE; AND ODS NOPROCTITLE;
ADVANCED TECHNIQUES
ODS DOCUMENT
PROC TEMPLATE
ADV SAS
13: INTRODUCTION TO PROC SQL
INTRODUCTION
WHY LEARN PROC SQL?
SELECT STATEMENT
THE SELECT STATEMENT SYNTAX
A SIMPLE PROC SQL
A COMPLEX PROC SQL
LIMITING INFORMATION ON THE SELECT
CREATING NEW VARIABLES
THE CALCULATED OPTION ON THE SELECT
USING LABELS AND FORMATS
THE CASE EXPRESSION ON THE SELECT
ADDITIONAL SELECT STATEMENT CLAUSES
REMERGING
REMERGING FOR TOTALS
CALCULATING PERCENTAGE
SORTING THE DATA IN PROC SQL
SORT ON NEW COLUMN
SUBSETTING USING THE WHERE
INCORRECT WHERE CLAUSE
WHERE ON COMPUTED COLUMN
SELECTION ON GROUP COLUMN
USE HAVING CLAUSE
CREATING NEW TABLES
JOINING DATASETS USING PROC SQL
INNER JOIN
JOINING THREE OR MORE TABLES
OUTER JOINS
INCLUDING NONMATCHING ROWS WITH THE RIGHT OUTER JOIN
SELECTING ALL ROWS WITH THE FULL OUTER JOIN
CONCATENATING QUERY RESULTS
14: AN INTRODUCTION TO SAS MACROS
INTRODUCTION
SAS MACRO OVERVIEW
TRADITIONAL SAS PROGRAMMING
THE SAS MACRO LANGUAGE
MACRO LANGUAGE COMPONENTS
MACRO VARIABLES
MACRO STATEMENTS
MACRO PROCESSOR FLOW
AUTOMATIC MACRO VARIABLES
MACRO DEBUGGING OPTIONS
WHAT IS A MACRO?
DEFINING AND USING MACROS
POSITIONAL MACRO PARAMETERS
KEYWORD MACRO PARAMETERS
CONDITIONAL MACRO COMPILATION
THE %DO STATEMENT
SAS DATA STEP INTERFACES
15: INTRODUCTION TO DIAGNOSING AND AVOIDING ERRORS
INTRODUCTION
UNDERSTANDING HOW THE SAS SUPERVISOR CHECKS A JOB
UNDERSTANDING HOW SAS PROCESSES ERRORS
DISTINGUISHING TYPES OF ERRORS .SAS RECOGNIZES FOUR KINDS OF ERRORS:
SYNTAX ERRORS
EXECUTION-TIME ERRORS
DATA ERRORS
SEMANTIC ERRORS
DIAGNOSING ERRORS
DIAGNOSING SYNTAX ERRORS
DIAGNOSING DATA ERRORS
USING A QUALITY CONTROL CHECKLIST
1: INTRODUCTION TO SAS
INTRODUCTION
NEED FOR SAS
WHO USES SAS
WHAT IS SAS?
OVERVIEW OF BASE SAS SOFTWARE
DATA MANAGEMENT FACILITY
STRUCTURE OF SAS DATASET
SAS PROGRAM
PROGRAMMING LANGUAGE
ELEMENTS OF THE SAS LANGUAGE
RULES FOR SAS STATEMENTS
RULES FOR MOST SAS NAMES
SPECIAL RULES FOR VARIABLE NAMES
TYPES OF VARIABLES
DATA ANALYSIS AND REPORTING UTILITIES
TRADITIONAL OUTPUT
WAYS TO RUN SAS PROGRAMS
SAS WINDOWING ENVIRONMENT
NONINTERACTIVE MODE
BATCH MODE
INTERACTIVE LINE MODE
RUNNING PROGRAMS IN THE SAS WINDOWING ENVIRONMENT
2: HOW SAS WORKS
WRITING YOUR FIRST SAS PROGRAM
A SIMPLE PROGRAM TO READ RAW DATA AND PRODUCE A REPORT
ENHANCING THE PROGRAM
MORE ON COMMENT STATEMENTS
INTERNAL PROCESSING IN SAS
HOW SAS WORKS
THE COMPILATION PHASE
THE EXECUTION PHASE
PROCESSING A DATA STEP: A WALKTHROUGH
CREATING THE INPUT BUFFER AND THE PROGRAM DATA VECTOR
WRITING AN OBSERVATION TO THE SAS DATA SET
FOUR TYPES OF SAS LIBRARIES
SAS LIBRARIES
WORK LIBRARY
SASHELP LIBRARY
SASUSER LIBRARY
3: READING RAW DATA INTO SAS
WHAT IS RAW DATA
DEFINITIONS
DATA VALUES
NUMERIC VALUE
CHARACTER VALUE
STANDARD DATA
NONSTANDARD DATA
NUMERIC DATA
CHARACTER DATA
CHOOSING AN INPUT STYLE
LIST INPUT
MODIFIED LIST INPUT
COLUMN INPUT
FORMATTED INPUT
NAMED INPUT
INSTREAM DATA
CREATING MULTIPLE RECORDS FROM SINGLE INPUT ROW
READING DATA FROM EXTERNAL FILES
READING BLANK SEPARATED VALUES (LIST OR FREE FORM DATA):
READING RAW DATA SEPARATED BY COMMAS (.CSV FILES):
READING IN RAW DATA SEPARATED BY TABS (.TXT FILES):
USING INFORMATS WITH LIST INPUT
SUPPLYING AN INFORMAT STATEMENT WITH LIST INPUT
USING LIST INPUT WITH EMBEDDED DELIMITERS
READING RAW DATA THAT ARE ALIGNED IN COLUMNS:
METHOD 1: COLUMN INPUT
METHOD 2: FORMATTED INPUT
USING MORE THAN ONE INPUT STATEMENT: THE SINGLE TRAILING @
READING COLUMN DATA THAT IS ON MORE THAN ONE LINE
MIXED-STYLE INPUT:
INFILE OPTIONS FOR SPECIAL SITUATIONS
FLOWOVER
MISSOVER
TRUNCOVER
PAD
USING LRECL TO READ VERY LONG LINES OF RAW DATA
CHECKING YOUR DATA AFTER IT HAS BEEN READ INTO SAS
4: READING DATA FROM A DATASET
INTRODUCTION
SET STATEMENT OVERVIEW
AUTOMATIC VARIABLES IN SAS
INTERLEAVE MULTIPLE SAS DATA SETS
COMBINE MULTIPLE SAS DATA SETS
CREATING & MODIFYING VARIABLES
CREATING MULTIPLE DATASETS IN A SINGLE DATA-STEP
SUBSETTING OBSERVATIONS
CONDITIONAL SAS STATEMENTS
LOGICAL AND SPECIAL OPERATORS
THE SAS SUPERVISOR AND THE SET STATEMENT
EFFICIENCY AND THE SET STATEMENT
KNOW YOUR DATA
SET STATEMENT DATA SET OPTIONS
DROP AND KEEP OPTIONS
RENAME OPTION
FIRSTOBS AND OBS OPTIONS
IN OPTION -
WHERE OPTION -
OTHER SET STATEMENT OPTIONS
END OPTION
KEY OPTION
NOBS OPTION
POINT OPTION
DO LOOPS AND THE SET STATEMENT
INTRODUCTION TO RETAIN STATEMENT
CARRY OVER VALUES FROM ONE OBSERVATION TO ANOTHER
COMPARE VALUES ACROSS OBSERVATIONS
ASSIGN INITIAL VALUES
DETERMINING COLUMN ORDER IN OUTPUT DATASET
SAS SYSTEM OPTIONS
5: READING DATA FROM A DATASET
INPUT SAS DATA SET FOR EXAMPLE
SELECTING OBSERVATIONS FOR A NEW SAS DATA SET
DELETING OBSERVATIONS BASED ON A CONDITION
ACCEPTING OBSERVATIONS BASED ON A CONDITION
COMPARING THE DELETE AND SUBSETTING IF STATEMENTS
METHODS OF CREATING NEW DATA SETS WITH A SUBSET
SUBSETTING RECORDS FROM AN EXTERNAL FILE WITH A SUBSETTING IF STATEMENT
SUBSETTING OBSERVATIONS IN A DATA STEP WITH A WHERE STATEMENT
SUBSETTING OBSERVATIONS IN A PROC STEP WITH A WHERE STATEMENT
SUBSETTING OBSERVATIONS IN PROC SQL
DIFFERENCE BETWEEN IF AND WHERE
6: SAS INFORMATS AND FORMATS
OVERVIEW
USING SAS INFORMATS
INPUT STATEMENT
INPUT FUNCTION
INPUTN AND INPUTC FUNCTIONS
ATTRIB AND INFORMAT STATEMENTS
USING SAS FORMATS
FORMAT STATEMENT IN PROCEDURES
PUT STATEMENT
PUT FUNCTION
PUTN AND PUTC FUNCTIONS
BESTw. Format
ADDITIONAL COMMENTS
7: SAS FUNCTIONS
CATEGORIES OF FUNCTIONS
SAS CHARACTER FUNCTIONS
FUNCTIONS THAT CHANGE THE CASE OF CHARACTERS
UPCASE
LOWCASE
PROPCASE
FUNCTIONS THAT REMOVE CHARACTERS FROM STRINGS
FUNCTION: COMPBL
FUNCTION: COMPRESS
FUNCTIONS THAT SEARCH FOR CHARACTERS
FUNCTION: ANYALNUM
FUNCTION: ANYALPHA
FUNCTION: ANYDIGIT
FUNCTION: ANYPUNCT
FUNCTION: ANYSPACE
FUNCTION: NOTALNUM
FUNCTION: NOTALPHA
FUNCTION: NOTDIGIT
FUNCTION: NOTUPPER
FUNCTIONS THAT SEARCH STRINGS
FIND AND FINDC
INDEX, INDEXC, AND INDEXW
FUNCTIONS TO VERIFY DATA
FUNCTION VERIFY
FUNCTIONS THAT EXTRACT PARTS OF STRINGS
FUNCTION: SUBSTR (ON THE LEFT-HAND SIDE OF THE EQUAL SIGN)
FUNCTION: SUBSTRN
FUNCTIONS THAT JOIN TWO OR MORE STRINGS TOGETHER
FUNCTION: CAT
FUNCTION: CATS
FUNCTION: CATT
FUNCTION: CATX
FUNCTIONS THAT REMOVE BLANKS FROM STRINGS
FUNCTION: LEFT
FUNCTION: RIGHT
FUNCTION: TRIM
FUNCTION: TRIMN
FUNCTION: STRIP
FUNCTIONS THAT COMPARE STRINGS
FUNCTION: COMPARE
FUNCTIONS THAT DIVIDE STRINGS INTO "WORDS"
FUNCTION: SCAN
FUNCTION: SCANQ
FUNCTIONS THAT SUBSTITUTE LETTERS OR WORDS IN STRINGS
FUNCTION: TRANSLATE
FUNCTION: TRANWRD
FUNCTIONS THAT COMPUTE THE LENGTH OF STRINGS
FUNCTION: LENGTH
FUNCTION: LENGTHC
FUNCTION: LENGTHM
FUNCTION: LENGTHN
FUNCTIONS THAT COUNT THE NUMBER OF LETTERS OR SUBSTRINGS IN A STRING
FUNCTION: COUNT
FUNCTION: COUNTC
MISCELLANEOUS STRING FUNCTIONS
FUNCTION: MISSING
FUNCTION: REPEAT
FUNCTION: REVERSE
SAS DATE AND TIME FUNCTIONS
INTRODUCTION
WHAT IS A SAS DATE AND TIME LITERAL?
DATE AND TIME FUNCTIONS
FUNCTINS TO CREATE DATE AND TIME VALUES
FUNCTIONS TO TAKIE DATETIME VALUES APART
FUNCTIONS TO GET QUARTER ,YEAR OR DAY OF THE DATE
FUNCTIONS THAT WORK WITH INTERVALS
USING FORMATS FOR DATE AND TIME
SYSTEM OPTIONS FORDATE AND TIME
8: AN INTRODUCTION TO ARRAYS AND ARRAY PROCESSING
WHY DO WE NEED ARRAYS?
BASIC ARRAY CONCEPTS
ARRAY STATEMENT
ARRAY REFERENCES
VARIABLE NAME ARRAY REFERENCE
USING ARRAY INDEXES
ONE DIMENSION ARRAYS
MULTI-DIMENSION ARRAYS
TEMPORARY ARRAYS
SORTING ARRAYS
Determining Array Bounds: LBOUND and HBOUND Functions
WHEN TO USE ARRAYS
COMMON ERRORS AND MISUNDERSTANDINGS
INVALID INDEX RANGE
FUNCTION NAME AS AN ARRAY NAME
ARRAY REFERENCED IN MULTIPLE DATA STEPS, BUT DEFINED IN ONLY ONE
9: BY - GROUP PROCESSING
DEFINITIONS FOR BY-GROUP PROCESSING
BY-GROUP PROCESSING
BY VALUE
BY GROUP
FIRST.VARIABLE AND LAST.VARIABLE
MODIFYING SAS DATA SETS: EXAMPLES.
INVOKING BY-GROUP PROCESSING
PREPROCESSING INPUT DATA FOR BY-GROUP PROCESSING
SORTING OBSERVATIONS FOR BY-GROUP PROCESSING
INDEXING FOR BY-GROUP PROCESSING
HOW THE DATA STEP IDENTIFIES BY GROUPS
PROCESSING OBSERVATIONS IN A BY GROUP
HOW SAS DETERMINES FIRST.VARIABLE AND LAST.VARIABLE
PROCESSING BY-GROUPS IN THE DATA STEP
OVERVIEW
PROCESSING BY-GROUPS CONDITIONALLY
DATA NOT IN ALPHABETIC OR NUMERIC ORDER
DATA GROUPED BY FORMATTED VALUES
10: OVERVIEW OF METHODS FOR COMBINING SAS DATA SETS
DEFINITIONS
CONCATENATING
INTERLEAVING
ONE-TO- ONE READING OR ONE-TO-ONE MERGING
MATCH-MERGING
UPDATING
MODIFYING
DEFINITIONS FOR READING, COMBINING, AND MODIFYING SAS DATA SETS
READING A SAS DATA SET
COMBINING SAS DATA SETS
MODIFYING SAS DATA SETS
OVERVIEW OF TOOLS
READING SAS DATA SETS
READING A SINGLE SAS DATA SET
READING FROM MULTIPLE SAS DATA SETS
COMBINING SAS DATA SETS: BASIC CONCEPTS
ONE-TO-ONE
ONE-TO-MANY AND MANY-TO-ONE
MANY-TO-MANY
ACCESS METHODS: SEQUENTIAL VERSUS DIRECT
SEQUENTIAL ACCESS
DIRECT ACCESS
ONE-TO-ONE READING
DATA STEP PROCESSING DURING A ONE-TO-ONE READING
ONE-TO-ONE MERGING
MATCH-MERGING
UPDATING WITH THE UPDATE AND THE MODIFY STATEMENTS :
DEFINITIONS
SYNTAX OF THE UPDATE STATEMENT
SYNTAX OF THE MODIFY STATEMENT -
UPDATING WITH NONMATCHED OBSERVATIONS, MISSING VALUES, AND NEW VARIABLES -
USING AN INDEX WITH THE MODIFY STATEMENT
11: SAS PROCEDURES
INTRODUCTION
THE ANATOMY OF A PROC
THE PROC STATEMENT
TITLE AND FOOTNOTE STATEMENTS
BY STATEMENT
LABEL STATEMENT
FORMAT STATEMENT
RUN OR QUIT STATEMENT
DESCRIPTION OF DATA USED IN REPORTS
SAS REPORTING PROCEDURES
PROCS FOR ALL THAT DETAIL
USING PROC PRINT
USING PROC SQL
PROC REPORT
PROCS THAT SUMMARIZE
USING PROC CHART
USING PROC FREQ
USING PROC MEANS
USING PROC UNIVARIATE
INTRODUCTION TO PROC TABULATE
DATA MANIPULATION AND MANAGEMENT PROCEDURE
PROC SORT
PROC DATASETS
PROC FORMAT
PROC CONTENTS
OTHER IMPORTANT PROCS
PROC TRANSPOSE
DEFINITIONS
PROC PRINTTO
COMPARE PROCEDURE
PROC APPEND
HOW TO IMPORT AN EXCEL FILE INTO SAS
12: INTRODUCTION TO PROC SQL
INTRODUCTION
WHY LEARN PROC SQL?
SELECT STATEMENT
THE SELECT STATEMENT SYNTAX
A SIMPLE PROC SQL
A COMPLEX PROC SQL
LIMITING INFORMATION ON THE SELECT
CREATING NEW VARIABLES
THE CALCULATED OPTION ON THE SELECT
USING LABELS AND FORMATS
THE CASE EXPRESSION ON THE SELECT
ADDITIONAL SELECT STATEMENT CLAUSES
REMERGING
REMERGING FOR TOTALS
CALCULATING PERCENTAGE
SORTING THE DATA IN PROC SQL
SORT ON NEW COLUMN
SUBSETTING USING THE WHERE
INCORRECT WHERE CLAUSE
WHERE ON COMPUTED COLUMN
SELECTION ON GROUP COLUMN
USE HAVING CLAUSE
CREATING NEW TABLES
JOINING DATASETS USING PROC SQL
INNER JOIN
JOINING THREE OR MORE TABLES
OUTER JOINS
INCLUDING NONMATCHING ROWS WITH THE RIGHT OUTER JOIN
SELECTING ALL ROWS WITH THE FULL OUTER JOIN
CONCATENATING QUERY RESULTS
13: AN INTRODUCTION TO SAS MACROS
INTRODUCTION
SAS MACRO OVERVIEW
TRADITIONAL SAS PROGRAMMING
THE SAS MACRO LANGUAGE
MACRO LANGUAGE COMPONENTS
MACRO VARIABLES
MACRO STATEMENTS
MACRO PROCESSOR FLOW
AUTOMATIC MACRO VARIABLES
MACRO DEBUGGING OPTIONS
WHAT IS A MACRO?
DEFINING AND USING MACROS
POSITIONAL MACRO PARAMETERS
KEYWORD MACRO PARAMETERS
CONDITIONAL MACRO COMPILATION
THE %DO STATEMENT
SAS DATA STEP INTERFACES
14: THE OUTPUT DELIVERY SYSTEM (ODS)
INTRODUCTION
CREATING VARIOUS TYPES OF REPORTS LISTING OUTPUT
OTHER DESTINATIONS
HTML
PDF AND POSTSCRIPT
RTF FILES
MICROSOFT EXCEL
ADDING STYLE TO YOUR REPORTS
LOCATE EXISTING STYLES
ODS STYLE= OPTION
CUSTOMIZE YOUR REPORTS
ODS SELECT; AND ODS EXCLUDE;
OTHER CUSTOMIZATIONS
ODS PROCLABEL= ;
ODS PROCTITLE; AND ODS NOPROCTITLE;
ADVANCED TECHNIQUES
ODS DOCUMENT
PROC TEMPLATE
15: INTRODUCTION TO DIAGNOSING AND AVOIDING ERRORS
INTRODUCTION
UNDERSTANDING HOW THE SAS SUPERVISOR CHECKS A JOB
UNDERSTANDING HOW SAS PROCESSES ERRORS
DISTINGUISHING TYPES OF ERRORS .SAS RECOGNIZES FOUR KINDS OF ERRORS:
SYNTAX ERRORS
EXECUTION-TIME ERRORS
DATA ERRORS
SEMANTIC ERRORS
DIAGNOSING ERRORS
DIAGNOSING SYNTAX ERRORS
DIAGNOSING DATA ERRORS
USING A QUALITY CONTROL CHECKLIST
16: Introduction to Clinical research
SAS ROLE IN CLINICAL RESEARCH
PROJECT MANAGEMENT IN CLINICAL RESEARCH
WHAT IS CLINICAL RESEARCH
WHAT IS PROTOCOL AND ROLE OF PROTOCOL IN CLINICAL RESEARCH?
WHAT IS RANDOMIZATION AND NON RANDOMIZATION?
WHICH IS PLAYING MAIN ROLE IN CLINICAL RESEARCH?
WHAT IS SOP (STANDARD OPERATING PROCEDURE)
ROLE OF DBMS TEAM IN CLINICAL RESEARCH
WHAT IS CDM (CLINICAL DATA MANAGEMENT)?
WHAT IS SAP (STATISTICAL ANALYSIS PLAN)?
ROLE OF SAP IN CLINICAL RESEARCH
SAS WORK FLOW IN CLINICAL RESEARCH
RELATION BETWEEN SAS AND DBMS
INTERACTION BETWEEN SAS WITH CDMS FOR DATA ACCESS
VARIOUS REPORT GENERATION IN CLINICAL RESEARCH
17: APPLICATION OF SAS IN CLINICAL DOMAIN
INTRODUCTION TO CLINICAL DOMAIN
DATA ACCESSING
DATA VALIDATION
DATA CLEANSING
PREPARING ANALYSIS DATASETS
DATA ANALYSIS
DATA PRESENTATION
REPORT VALIDATION
PRACTICAL APPLICATION WITH PROJECT
1: INTRODUCTION TO SAS
INTRODUCTION
NEED FOR SAS
WHO USES SAS
WHAT IS SAS?
OVERVIEW OF BASE SAS SOFTWARE
DATA MANAGEMENT FACILITY
STRUCTURE OF SAS DATASET
SAS PROGRAM
PROGRAMMING LANGUAGE
ELEMENTS OF THE SAS LANGUAGE
RULES FOR SAS STATEMENTS
RULES FOR MOST SAS NAMES
SPECIAL RULES FOR VARIABLE NAMES
TYPES OF VARIABLES
DATA ANALYSIS AND REPORTING UTILITIES
TRADITIONAL OUTPUT
WAYS TO RUN SAS PROGRAMS
SAS WINDOWING ENVIRONMENT
NONINTERACTIVE MODE
BATCH MODE
INTERACTIVE LINE MODE
RUNNING PROGRAMS IN THE SAS WINDOWING ENVIRONMENT
2: HOW SAS WORKS
WRITING YOUR FIRST SAS PROGRAM
A SIMPLE PROGRAM TO READ RAW DATA AND PRODUCE A REPORT
ENHANCING THE PROGRAM
MORE ON COMMENT STATEMENTS
INTERNAL PROCESSING IN SAS
HOW SAS WORKS
THE COMPILATION PHASE
THE EXECUTION PHASE
PROCESSING A DATA STEP: A WALKTHROUGH
CREATING THE INPUT BUFFER AND THE PROGRAM DATA VECTOR
WRITING AN OBSERVATION TO THE SAS DATA SET
FOUR TYPES OF SAS LIBRARIES
SAS LIBRARIES
WORK LIBRARY
SASHELP LIBRARY
SASUSER LIBRARY
3: READING RAW DATA INTO SAS
WHAT IS RAW DATA
DEFINITIONS
DATA VALUES
NUMERIC VALUE
CHARACTER VALUE
STANDARD DATA
NONSTANDARD DATA
NUMERIC DATA
CHARACTER DATA
CHOOSING AN INPUT STYLE
LIST INPUT
MODIFIED LIST INPUT
COLUMN INPUT
FORMATTED INPUT
NAMED INPUT
INSTREAM DATA
CREATING MULTIPLE RECORDS FROM SINGLE INPUT ROW
READING DATA FROM EXTERNAL FILES
READING BLANK SEPARATED VALUES (LIST OR FREE FORM DATA):
READING RAW DATA SEPARATED BY COMMAS (.CSV FILES):
READING IN RAW DATA SEPARATED BY TABS (.TXT FILES):
USING INFORMATS WITH LIST INPUT
SUPPLYING AN INFORMAT STATEMENT WITH LIST INPUT
USING LIST INPUT WITH EMBEDDED DELIMITERS
READING RAW DATA THAT ARE ALIGNED IN COLUMNS:
METHOD 1: COLUMN INPUT
METHOD 2: FORMATTED INPUT
USING MORE THAN ONE INPUT STATEMENT: THE SINGLE TRAILING @
READING COLUMN DATA THAT IS ON MORE THAN ONE LINE
MIXED-STYLE INPUT:
INFILE OPTIONS FOR SPECIAL SITUATIONS
FLOWOVER
MISSOVER
TRUNCOVER
PAD
USING LRECL TO READ VERY LONG LINES OF RAW DATA
CHECKING YOUR DATA AFTER IT HAS BEEN READ INTO SAS
4: READING DATA FROM A DATASET
INTRODUCTION
SET STATEMENT OVERVIEW
AUTOMATIC VARIABLES IN SAS
INTERLEAVE MULTIPLE SAS DATA SETS
COMBINE MULTIPLE SAS DATA SETS
CREATING & MODIFYING VARIABLES
CREATING MULTIPLE DATASETS IN A SINGLE DATA-STEP
SUBSETTING OBSERVATIONS
CONDITIONAL SAS STATEMENTS
LOGICAL AND SPECIAL OPERATORS
THE SAS SUPERVISOR AND THE SET STATEMENT
EFFICIENCY AND THE SET STATEMENT
KNOW YOUR DATA
SET STATEMENT DATA SET OPTIONS
DROP AND KEEP OPTIONS
RENAME OPTION
FIRSTOBS AND OBS OPTIONS
IN OPTION -
WHERE OPTION -
OTHER SET STATEMENT OPTIONS
END OPTION
KEY OPTION
NOBS OPTION
POINT OPTION
DO LOOPS AND THE SET STATEMENT
INTRODUCTION TO RETAIN STATEMENT
CARRY OVER VALUES FROM ONE OBSERVATION TO ANOTHER
COMPARE VALUES ACROSS OBSERVATIONS
ASSIGN INITIAL VALUES
DETERMINING COLUMN ORDER IN OUTPUT DATASET
SAS SYSTEM OPTIONS
5: READING DATA FROM A DATASET
INPUT SAS DATA SET FOR EXAMPLE
SELECTING OBSERVATIONS FOR A NEW SAS DATA SET
DELETING OBSERVATIONS BASED ON A CONDITION
ACCEPTING OBSERVATIONS BASED ON A CONDITION
COMPARING THE DELETE AND SUBSETTING IF STATEMENTS
METHODS OF CREATING NEW DATA SETS WITH A SUBSET
SUBSETTING RECORDS FROM AN EXTERNAL FILE WITH A SUBSETTING IF STATEMENT
SUBSETTING OBSERVATIONS IN A DATA STEP WITH A WHERE STATEMENT
SUBSETTING OBSERVATIONS IN A PROC STEP WITH A WHERE STATEMENT
SUBSETTING OBSERVATIONS IN PROC SQL
DIFFERENCE BETWEEN IF AND WHERE
6: SAS INFORMATS AND FORMATS
OVERVIEW
USING SAS INFORMATS
INPUT STATEMENT
INPUT FUNCTION
INPUTN AND INPUTC FUNCTIONS
ATTRIB AND INFORMAT STATEMENTS
USING SAS FORMATS
FORMAT STATEMENT IN PROCEDURES
PUT STATEMENT
PUT FUNCTION
PUTN AND PUTC FUNCTIONS
BESTw. Format
ADDITIONAL COMMENTS
7: SAS FUNCTIONS
CATEGORIES OF FUNCTIONS
SAS CHARACTER FUNCTIONS
FUNCTIONS THAT CHANGE THE CASE OF CHARACTERS
UPCASE
LOWCASE
PROPCASE
FUNCTIONS THAT REMOVE CHARACTERS FROM STRINGS
FUNCTION: COMPBL
FUNCTION: COMPRESS
FUNCTIONS THAT SEARCH FOR CHARACTERS
FUNCTION: ANYALNUM
FUNCTION: ANYALPHA
FUNCTION: ANYDIGIT
FUNCTION: ANYPUNCT
FUNCTION: ANYSPACE
FUNCTION: NOTALNUM
FUNCTION: NOTALPHA
FUNCTION: NOTDIGIT
FUNCTION: NOTUPPER
FUNCTIONS THAT SEARCH STRINGS
FIND AND FINDC
INDEX, INDEXC, AND INDEXW
FUNCTIONS TO VERIFY DATA
FUNCTION VERIFY
FUNCTIONS THAT EXTRACT PARTS OF STRINGS
FUNCTION: SUBSTR (ON THE LEFT-HAND SIDE OF THE EQUAL SIGN)
FUNCTION: SUBSTRN
FUNCTIONS THAT JOIN TWO OR MORE STRINGS TOGETHER
FUNCTION: CAT
FUNCTION: CATS
FUNCTION: CATT
FUNCTION: CATX
FUNCTIONS THAT REMOVE BLANKS FROM STRINGS
FUNCTION: LEFT
FUNCTION: RIGHT
FUNCTION: TRIM
FUNCTION: TRIMN
FUNCTION: STRIP
FUNCTIONS THAT COMPARE STRINGS
FUNCTION: COMPARE
FUNCTIONS THAT DIVIDE STRINGS INTO "WORDS"
FUNCTION: SCAN
FUNCTION: SCANQ
FUNCTIONS THAT SUBSTITUTE LETTERS OR WORDS IN STRINGS
FUNCTION: TRANSLATE
FUNCTION: TRANWRD
FUNCTIONS THAT COMPUTE THE LENGTH OF STRINGS
FUNCTION: LENGTH
FUNCTION: LENGTHC
FUNCTION: LENGTHM
FUNCTION: LENGTHN
FUNCTIONS THAT COUNT THE NUMBER OF LETTERS OR SUBSTRINGS IN A STRING
FUNCTION: COUNT
FUNCTION: COUNTC
MISCELLANEOUS STRING FUNCTIONS
FUNCTION: MISSING
FUNCTION: REPEAT
FUNCTION: REVERSE
SAS DATE AND TIME FUNCTIONS
INTRODUCTION
WHAT IS A SAS DATE AND TIME LITERAL?
DATE AND TIME FUNCTIONS
FUNCTINS TO CREATE DATE AND TIME VALUES
FUNCTIONS TO TAKIE DATETIME VALUES APART
FUNCTIONS TO GET QUARTER ,YEAR OR DAY OF THE DATE
FUNCTIONS THAT WORK WITH INTERVALS
USING FORMATS FOR DATE AND TIME
SYSTEM OPTIONS FORDATE AND TIME
8: AN INTRODUCTION TO ARRAYS AND ARRAY PROCESSING
WHY DO WE NEED ARRAYS?
BASIC ARRAY CONCEPTS
ARRAY STATEMENT
ARRAY REFERENCES
VARIABLE NAME ARRAY REFERENCE
USING ARRAY INDEXES
ONE DIMENSION ARRAYS
MULTI-DIMENSION ARRAYS
TEMPORARY ARRAYS
SORTING ARRAYS
Determining Array Bounds: LBOUND and HBOUND Functions
WHEN TO USE ARRAYS
COMMON ERRORS AND MISUNDERSTANDINGS
INVALID INDEX RANGE
FUNCTION NAME AS AN ARRAY NAME
ARRAY REFERENCED IN MULTIPLE DATA STEPS, BUT DEFINED IN ONLY ONE
9: BY - GROUP PROCESSING
DEFINITIONS FOR BY-GROUP PROCESSING
BY-GROUP PROCESSING
BY VALUE
BY GROUP
FIRST.VARIABLE AND LAST.VARIABLE
MODIFYING SAS DATA SETS: EXAMPLES.
INVOKING BY-GROUP PROCESSING
PREPROCESSING INPUT DATA FOR BY-GROUP PROCESSING
SORTING OBSERVATIONS FOR BY-GROUP PROCESSING
INDEXING FOR BY-GROUP PROCESSING
HOW THE DATA STEP IDENTIFIES BY GROUPS
PROCESSING OBSERVATIONS IN A BY GROUP
HOW SAS DETERMINES FIRST.VARIABLE AND LAST.VARIABLE
PROCESSING BY-GROUPS IN THE DATA STEP
OVERVIEW
PROCESSING BY-GROUPS CONDITIONALLY
DATA NOT IN ALPHABETIC OR NUMERIC ORDER
DATA GROUPED BY FORMATTED VALUES
10: OVERVIEW OF METHODS FOR COMBINING SAS DATA SETS
DEFINITIONS
CONCATENATING
INTERLEAVING
ONE-TO- ONE READING OR ONE-TO-ONE MERGING
MATCH-MERGING
UPDATING
MODIFYING
DEFINITIONS FOR READING, COMBINING, AND MODIFYING SAS DATA SETS
READING A SAS DATA SET
COMBINING SAS DATA SETS
MODIFYING SAS DATA SETS
OVERVIEW OF TOOLS
READING SAS DATA SETS
READING A SINGLE SAS DATA SET
READING FROM MULTIPLE SAS DATA SETS
COMBINING SAS DATA SETS: BASIC CONCEPTS
ONE-TO-ONE
ONE-TO-MANY AND MANY-TO-ONE
MANY-TO-MANY
ACCESS METHODS: SEQUENTIAL VERSUS DIRECT
SEQUENTIAL ACCESS
DIRECT ACCESS
ONE-TO-ONE READING
DATA STEP PROCESSING DURING A ONE-TO-ONE READING
ONE-TO-ONE MERGING
MATCH-MERGING
UPDATING WITH THE UPDATE AND THE MODIFY STATEMENTS :
DEFINITIONS
SYNTAX OF THE UPDATE STATEMENT
SYNTAX OF THE MODIFY STATEMENT -
UPDATING WITH NONMATCHED OBSERVATIONS, MISSING VALUES, AND NEW VARIABLES -
USING AN INDEX WITH THE MODIFY STATEMENT
11: SAS PROCEDURES
INTRODUCTION
THE PROC STATEMENT
TITLE AND FOOTNOTE STATEMENTS
BY STATEMENT
LABEL STATEMENT
FORMAT STATEMENT
RUN OR QUIT STATEMENT
DESCRIPTION OF DATA USED IN REPORTS
SAS REPORTING PROCEDURES
PROCS FOR ALL THAT DETAIL
USING PROC PRINT
USING PROC SQL
PROC REPORT
PROCS THAT SUMMARIZE
USING PROC CHART
USING PROC FREQ
USING PROC MEANS
USING PROC UNIVARIATE
INTRODUCTION TO PROC TABULATE
DATA MANIPULATION AND MANAGEMENT PROCEDURE
PROC SORT
PROC DATASETS
PROC FORMAT
PROC CONTENTS
OTHER IMPORTANT PROCS
PROC TRANSPOSE
DEFINITIONS
PROC PRINTTO
COMPARE PROCEDURE
PROC APPEND
HOW TO IMPORT AN EXCEL FILE INTO SAS
12: INTRODUCTION TO PROC SQL
INTRODUCTION
WHY LEARN PROC SQL?
SELECT STATEMENT
THE SELECT STATEMENT SYNTAX
A SIMPLE PROC SQL
A COMPLEX PROC SQL
LIMITING INFORMATION ON THE SELECT
CREATING NEW VARIABLES
THE CALCULATED OPTION ON THE SELECT
USING LABELS AND FORMATS
THE CASE EXPRESSION ON THE SELECT
ADDITIONAL SELECT STATEMENT CLAUSES
REMERGING
REMERGING FOR TOTALS
CALCULATING PERCENTAGE
SORTING THE DATA IN PROC SQL
SORT ON NEW COLUMN
SUBSETTING USING THE WHERE
INCORRECT WHERE CLAUSE
WHERE ON COMPUTED COLUMN
SELECTION ON GROUP COLUMN
USE HAVING CLAUSE
CREATING NEW TABLES
JOINING DATASETS USING PROC SQL
INNER JOIN
JOINING THREE OR MORE TABLES
OUTER JOINS
INCLUDING NONMATCHING ROWS WITH THE RIGHT OUTER JOIN
SELECTING ALL ROWS WITH THE FULL OUTER JOIN
CONCATENATING QUERY RESULTS
13: SAS FINANCE PROCEDURES
PROC LOAN
PROC TIMESERIES
PROC FORECASTING
PROC UPLOAD
PROC DOWNLOAD
PROC EXPAND
PROC UCM
PROC CLUSTER
PROC DISTANCE
PROC TREE
14: AN INTRODUCTION TO SAS MACROS
INTRODUCTION
SAS MACRO OVERVIEW
TRADITIONAL SAS PROGRAMMING
THE SAS MACRO LANGUAGE
MACRO LANGUAGE COMPONENTS
MACRO VARIABLES
MACRO STATEMENTS
MACRO PROCESSOR FLOW
AUTOMATIC MACRO VARIABLES
MACRO DEBUGGING OPTIONS
WHAT IS A MACRO?
DEFINING AND USING MACROS
POSITIONAL MACRO PARAMETERS
KEYWORD MACRO PARAMETERS
CONDITIONAL MACRO COMPILATION
THE %DO STATEMENT
SAS DATA STEP INTERFACES
15: THE OUTPUT DELIVERY SYSTEM (ODS)
INTRODUCTION
CREATING VARIOUS TYPES OF REPORTS LISTING OUTPUT
OTHER DESTINATIONS
HTML
PDF AND POSTSCRIPT
RTF FILES
MICROSOFT EXCEL
ADDING STYLE TO YOUR REPORTS
LOCATE EXISTING STYLES
ODS STYLE= OPTION
CUSTOMIZE YOUR REPORTS
ODS SELECT; AND ODS EXCLUDE;
OTHER CUSTOMIZATIONS
ODS PROCLABEL= ;
ODS PROCTITLE; AND ODS NOPROCTITLE;
ADVANCED TECHNIQUES
ODS DOCUMENT
PROC TEMPLATE
16: INTRODUCTION TO DIAGNOSING AND AVOIDING ERRORS
INTRODUCTION
UNDERSTANDING HOW THE SAS SUPERVISOR CHECKS A JOB
UNDERSTANDING HOW SAS PROCESSES ERRORS
DISTINGUISHING TYPES OF ERRORS .SAS RECOGNIZES FOUR KINDS OF ERRORS:
SYNTAX ERRORS
EXECUTION-TIME ERRORS
DATA ERRORS
SEMANTIC ERRORS
DIAGNOSING ERRORS
DIAGNOSING SYNTAX ERRORS
DIAGNOSING DATA ERRORS
USING A QUALITY CONTROL CHECKLIST