Base SAS Software

The features provided by SAS/ETS software are extensions to the features provided by Base SAS software. Many data management and reporting capabilities you need are part of Base SAS software. Refer to SAS Language Reference: Dictionary and Base SAS Procedures Guide for documentation of Base SAS software. In particular, refer to Base SAS Procedures Guide: Statistical Procedures for information about statistical analysis features included with Base SAS.

The following sections summarize Base SAS software features of interest to users of SAS/ETS software. See Chapter 3: Working with Time Series Data, for further discussion of some of these topics as they relate to time series data and SAS/ETS software.

SAS DATA Step

The DATA step is your primary tool for reading and processing data in the SAS System. The DATA step provides a powerful general purpose programming language that enables you to perform all kinds of data processing tasks. The DATA step is documented in SAS Language Reference: Dictionary.

Base SAS Procedures

Base SAS software includes many useful SAS procedures, which are documented in Base SAS Procedures Guide and Base SAS Procedures Guide: Statistical Procedures. The following is a list of Base SAS procedures you might find useful:

CATALOG

for managing SAS catalogs

CHART

for printing charts and histograms

COMPARE

for comparing SAS data sets

CONTENTS

for displaying the contents of SAS data sets

COPY

for copying SAS data sets

CORR

for computing correlations

CPORT

for moving SAS data libraries between computer systems

DATASETS

for deleting or renaming SAS data sets

FCMP

for compiling functions for use in SAS programs. The SAS Function Compiler Procedure (FCMP) enables you to create, test, and store SAS functions and subroutines before you use them in other SAS procedures. PROC FCMP accepts slight variations of DATA step statements, and most features of the SAS programm

ing language can be used in functions and subroutines that are processed by PROC FCMP.

FREQ

for computing frequency crosstabulations

MEANS

for computing descriptive statistics and summarizing or collapsing data over cross sections

PLOT

for printing scatter plots

PRINT

for printing SAS data sets

PROTO

for accessing external functions from the SAS system. The PROTO procedure enables you to register external functions that are written in the C or C++ programming languages. You can use these functions in SAS as well as in C-language structures and types. After the C-language functions are registered in PROC

PROTO, they can be called from any SAS function or subroutine that is declared in the FCMP procedure, as well as from any SAS function, subroutine, or method block that is declared in the COMPILE procedure.

RANK

for computing rankings or order statistics

SORT

for sorting SAS data sets

SQL

for processing SAS data sets with Structured Query Language

STANDARD

for standardizing variables to a fixed mean and variance

TABULATE

for printing descriptive statistics in tabular format

TIMEPLOT

for plotting variables over time

TRANSPOSE

for transposing SAS data sets

UNIVARIATE

for computing descriptive statistics

Global Statements

Global statements can be specified anywhere in your SAS program, and they remain in effect until changed. Global statements are documented in SAS Language Reference: Dictionary. You may find the following SAS global statements useful:

FILENAME

for accessing data files

FOOTNOTE

for printing footnote lines at the bottom of each page

%INCLUDE

for including files of SAS statements

LIBNAME

for accessing SAS data libraries

OPTIONS

for setting various SAS system options

QUIT

for ending an interactive procedure step

RUN

for executing the preceding SAS statements

TITLE

for printing title lines at the top of each page

X

for issuing host operating system commands from within your SAS session

Some Base SAS statements can be used with any SAS procedure, including SAS/ETS procedures. These statements are not global, and they affect only the SAS procedure they are used with. These statements are documented in SAS Language Reference: Dictionary.

The following Base SAS statements are useful with SAS/ETS procedures:

BY

for computing separate analyses for groups of observations

FORMAT

for assigning formats to variables

LABEL

for assigning descriptive labels to variables

WHERE

for subsetting data to restrict the range of data processed or to select or exclude observations from the analysis

SAS Functions

SAS functions can be used in DATA step programs and in the COMPUTAB and MODEL procedures. The following kinds of functions are available:

  • character functions for manipulating character strings

  • date and time functions for performing date and calendar calculations

  • financial functions for performing financial calculations such as depreciation, net present value, periodic savings, and internal rate of return

  • lagging and differencing functions for computing lags and differences

  • mathematical functions for computing data transformations and other mathematical calculations

  • probability functions for computing quantiles of statistical distributions and the significance of test statistics

  • random number functions for simulation experiments

  • sample statistics functions for computing means, standard deviations, kurtosis, and so forth

SAS functions are documented in SAS Language Reference: Dictionary. Chapter 3: Working with Time Series Data, discusses the use of date, time, lagging, and differencing functions. Chapter 4: Date Intervals, Formats, and Functions, contains a reference list of date and time functions.

Formats, Informats, and Time Intervals

Base SAS software provides formats to control the printing of data values, informats to read data values, and time intervals to define the frequency of time series. See Chapter 4: Date Intervals, Formats, and Functions, for more information.