Module 1: Basics Flashcards
Define a SAS Statement
is a SAS language element used to perform a particular operation in a SAS program or to provide info to a SAS program
T/F: SAS statements are not case senstive.
True (unless enclosed in quotes)
T/F: Statements cannot continue over several lines.
False: its free format
What are the two types of steps?
1) Data steps that can manipulate data
2) Proc steps that helps analyze data
Define a global statement.
A statement that can be used throughout a program until its changed, cancelled, or SAS ends.
Ex. title, libname, options
What happends when the RUN statement is not used a the end of a data step?
SAS assumes that the beginning of a new step implies the end of a previous step.
Why should you include the run statement at the end of a step?
Helps makes statements and log easier to read
What are the naming rules for SAS files?
1) Must begin with a letter or an underscore
2) can be any combination of letters,numbers, or underscores
3) can be 1-32 characters long
What is a SAS library?
A storage unit for SAS system files.
What are temporary files and their properties?
Temporary and end when SAS section closes
Default is WORK unless specified.
Can be referenced by name only.
What are permanent Files and their properties?
Available after the end of the current session.
Must define library and then tell SAS to store there.
What are the rules to library names?
1)Begin with a letter or underscore
2) Can continue with other combinations of letters, numbers, or underscores.
3) Can by 1-8 characters long
4) Must be assigned in each SAS session
Write the syntax to creating libraries.
libname NAME ‘PATH’;
capital letters means that is what you name it.
Lowercase is actual code
Write the syntax to reference a permanent file.
LIBREF.FILENAME
Write the syntax to reference an externam file
filename FILEREF ‘path’;