Base SAS Sample Programs
Table of Contents
If the sample is untitled, it is listed by its original filename.
Image Demo
Base Procedures Guide Examples
Elementary Statistics Procedures, Chapter 1
Reporting Procedures, Chapter 2
APPEND Procedure, Chapter 5
CALENDAR Procedure, Chapter 7
CHART Procedure, Chapter 9
COMPARE Procedure, Chapter 11
CORR Procedure, Chapter 15
FORMAT Procedure, Chapter 18
FORMS Procedure, Chapter 19
FREQ Procedure, Chapter 20
MEANS Procedure, Chapter 21
PLOT Procedure, Chapter 25
PRINT Procedure, Chapter 27
RANK Procedure, Chapter 29
SQL Procedure, Chapter 34
STANDARD Procedure, Chapter 35
TABULATE Procedure, Chapter 37
TIMEPLOT Procedure, Chapter 40
TRANSPOSE Procedure, Chapter 41
UNIVARIATE Procedure, Chapter 42
Base Usage Guide Examples
What is the SAS System?, Chapter 1
Introduction to DATA Step Processing, Chapter 2
Starting with Raw Data, Chapter 3
Starting with SAS Data Sets, Chapter 4
Understanding DATA Step Processing, Chapter 5
Working with Numeric Variables, Chapter 6
Working with Character Variables, Chapter 7
Acting on Selected Observations, Chapter 8
Creating Subsets of Observations, Chapter 9
Grouped or Sorted Observations, Chapter 10
More than One Obs. in a Calculation, Chapter 11
Finding Shortcuts in Programming, Chapter 12
Working with Dates in the SAS System, Chapter 13
Concatenating SAS Data Sets, Chapter 15
Interleaving SAS Data Sets, Chapter 16
Merging SAS Data Sets, Chapter 17
Updating SAS Data Sets, Chapter 18
Manipulating SAS Data Sets, Chapter 19
Understanding and Enhancing Your Output, Chapter 20
Printing Detailed Reports, Chapter 24
Creating Summary Tables, Chapter 25
Mailing Labels and Other Forms, Chapter 26
Plotting Relationships Between Variables, Chap. 27
Charting the Values of a Variable, Chapter 28
Writing Output, Chapter 29
Customizing Output, Chapter 30
ODS Examples
Basic Functionality of Document
Basic Functionality of Document Link Statement
Basic Functionality of Document Replay Statement
Demonstrates Anova Embedded Graphs
Demonstrates Basic Files Generated from HTML
Demonstrates ODS Select and Exclude Statements
Demonstrates ODS Generating Output Data Sets
Demonstrates ODS Selective Output
Demonstrates JAVA Output
Demonstrates Basic Files Generated from ODS MARKUP
Demonstrates Basic Files Generated from ODS MARKUP
Demonstrates Basic Files Generated from ODS MARKUP
Demonstrates Basic Files Generated from ODS MARKUP
Demonstrates Basic Files Generated from ODS MARKUP
Demonstrates Basic Files Generated from ODS MARKUP
Demonstrates Basic Files Generated from ODS MARKUP
Demonstrates Basic Files Generated from ODS MARKUP
Demonstrates Basic Files Generated from ODS MARKUP
Demonstrates Basic Files Generated from ODS MARKUP
Demonstrates ODS Printer Output in various Fonts
Generates ODS Output Data Sets
Demonstrates ODS Styles with PROC REPORT
Demonstrates Style Identifiers with PROC REPORT
Demonstrates Embedded Graphs with PROC REPORT
Demonstrates Embedded Links with PROC REPORT
Demonstrates Embedded Links with GRAPH and REPORT
Demonstrates New Version 7 Features in PROC SUMMARY
Demonstrates use of CLASSDATA= in PROC SUMMARY
Demonstrates Use of TopN Modifier with PROC SUMMARY
Demonstrates Use of PRELOADFMT with PROC SUMMARY
Demonstrates Use of PRELOADFMT with PROC TABULATE
Demonstrates Additional Tabular PRELOADFMT Output
Demonstrates PROC TABULATE Data Set Output
Demonstrates Use of PCTSUM in PROC TABULATE
Demonstrates ODS Styles with PROC TABULATE
Demonstrates Dynamic HTML with PROC TABULATE
Demonstrates POSTIMAGE Style with PROC TABULATE
Demonstrates POSTHTML STYLE with PROC TABULATE
Demonstrates Highlighting Cells with PROC TABULATE
Demonstrates Use of Banding in PROC TABULATE
Demonstrates Custom ODS Styles with Weblink
Demonstrates Customized Templates (I)
Demonstrates Customized Templates (II)
Demonstrates Stack Columns using PROC TEMPLATE
Demonstrates ODS and Data Step using PROC TEMPLATE
Demonstrates Customized Table, Header, and Column
Demonstrates Customized Table, Header, and Column
SQL Examples
Demonstrates Basic SQL SELECT Statements
Demonstrates Basic SQL CREATE Statements
Demonstrates Basic SQL DELETE Statements
Demonstrates Basic SQL Dictionary Statements
Demonstrates Basic SQL Insert Statements
Demonstrates SQL Join Performance with Macros
Demonstrates Basic SQL JOIN Features
Demonstrates SQL Set Operators
Introduction to the SQL Procedure, Chapter 1
Retrieving Data with the SELECT Statement, Chapter 2
Datasets Used in SQL Usage Guide
Demonstrates Basic SQL UPDATE Statements
Demonstrates SQL View Capabilities
Demonstrates SQL View Update Capabilities
Demonstrates Recursive Joins with PROC SQL
Demonstrates Nested Statistics with SQL
Demonstrates CASE Statement with PROC SQL
Demonstrates the Product of Columns with PROC SQL
Demonstrates Merging Tables with Proc SQL
Demonstrates Use of Macros with PROC SQL
Demonstrates Use of Cartesian Product with PROC SQL
More Uses of the Cartesian Product with PROC SQL
Demonstrates Use of Subqueries with PROC SQL
Demonstrates Relationship Between Data Step and SQL
Miscellaneous
Adding new observations to a SAS Data Set
Examples of using the SAS Interface to the ARM API
Biorhythm Cycle Plots
Creating a Yearly Calendar
Creating Summaries and Schedules with PROC CALENDAR
Generating Hbar, Vbar, Block, Pie, and Star Charts
Producing a Pie Chart
Creating CHI-SQUARED Probability Plots
Comparison of Two Data Sets Using PROC COMPARE
Display Attributes of a Data Set Using PROC CONTENTS
SAS Institute, Inc. Copyright Statement
Getting Started Example for PROC CORR
Documentation Example 1 for PROC CORR
Documentation Example 2 for PROC CORR
Documentation Example 3 for PROC CORR
Documentation Example 4 for PROC CORR
Documentation Example 5 for PROC CORR
Documentation Example 6 for PROC CORR
Documentation Example 7 for PROC CORR
Basic Data Set Manipulations
Simple and Composite Indexes
Using SYMPUT & SYMGET Reporting
Exponential Probability Plotting
Generating Value Statements Using PROC FORMAT
Sample Picture Formats Using PROC FORMAT
Creating Duplicate Mailing Labels
Frequency and Cross Tabulations
Frequency and Crosstabulation Tables
Computing Geometric Means
Color/Gray Scale Test Pattern Screen
importad.sas
importpw.sas
Index Program for Samples
Computes Moving Average
Simple Descriptive Statistics
Election Merge, Three-Way Merge
Every Possible Merge Combination
Normal Probability Plot
Report Writer to Produce Paychecks
U.S. Population Density Plot
Principal Components of Crime Rates Plot
Assorted Label Plot Examples
Plot with Reference Line at Mean of Each by Group
Report Writing Using PROC PRINT
Ranking Observations
Ranking Gain Values
Report Writing Using PUT Statement for Entire Page
Payroll Report Writing Using PUT Statement
Report Writing Using PROC PRINT (YTD Totals)
Report Writing Using PUT Statement (I)
Report Writing Using PUT Statement (II)
Examples from the SAS Guide to the REPORT Procedure
Selecting a Sample of K Observations from a Data Set
Reproducing Input with Sequence Numbers
Standardizing Test Scores
Format Tables for State Codes
Monthly Usage of Statistical Systems
Hbar Chart Examples from SUGI Demo
Creating Address Labels
HIGH - LOW: A Simple Game
SUGI Example
Simple Descriptive Statistics (I)
Simple Descriptive Statistics (II)
Hierarchical Tables
Stock Market Reporting
Creating a Similarity Rating Form
Transposing a Large Data Set
Resolving Trees by Sorting and Merging
Documentation Examples 1, 3, 11
Documentation Example 2
Documentation Examples 4, 13
Documentation Example 5
Documentation Example 6
Documentation Examples 7, 8
Documentation Example 9, 10, 12
Documentation Examples 14, 18, 19
Documentation Examples 15, 20, 23
Documentation Example 16
Documentation Example 17
Documentation Example 21
Documentation Example 22
Documentation Example 24
Documentation Example 25
Documentation Examples 26, 27
Documentation Examples 28, 29
Documentation Examples 30, 31, 32, 33
Documentation Example 34
Documentation Getting Started Code
Documentation Getting Started
Documentation Getting Started
Updating a Bank Master File
Textual Analysis of Word Frequency