Preview

knowing

Powerful Essays
Open Document
Open Document
1842 Words
Grammar
Grammar
Plagiarism
Plagiarism
Writing
Writing
Score
Score
knowing
P a r t

1

Understanding the Concepts and Features of
Macro Programming
Chapter 1

Introduction

3

Chapter 2

Mechanics of Macro Processing

Chapter 3

Macro Variables

39

Chapter 4

Macro Programs

73

Chapter 5

Understanding Macro Symbol Tables and the Processing of
Macro Programs 101

Chapter 6

Macro Language Functions

Chapter 7

Macro Expressions and Macro Programming
Statements 159

Chapter 8

Masking Special Characters and Mnemonic
Operators 189

Chapter 9

Interfaces to the Macro Facility

23

133

217

2 SAS Macro Programming Made Easy, Second Edition

C h a p t e r

1

Introduction
What Is the SAS Macro Facility? 4
What Are the Advantages of the SAS Macro Facility? 6
Where Can the SAS Macro Facility Be Used? 12
Examples of the SAS Macro Facility 13
Imagine you have an assistant to help you write your SAS programs. Your assistant willingly and unfailingly follows your instructions allowing you to move on to other tasks. Repetitive programming assignments like multiple PROC TABULATE tables, where the only difference between one table and the next is the classification variable, are delegated to your assistant. Jobs that require you to run a few steps, review the output, and then run additional steps based on the output are not difficult; they are, however, time-consuming. With instructions on selection of subsequent steps, your assistant easily handles the work. Even having your assistant do simple tasks like editing information in TITLE statements makes your job easier.
Actually, you already have a SAS programming assistant: the SAS macro facility. The
SAS macro facility can do all the tasks above and more. To have the macro facility work for you, you first need to know how to communicate with the macro facility. That's the purpose of this book: to show you how to communicate with the SAS macro facility so that your SAS programming can become more effective and

You May Also Find These Documents Helpful