Loading...

Types of Macro in Advanced SAS


SAS macro variables are part of the macro facility, which is a tool for extending and customizing SAS software. These Macro variables facilitates programmers to replace text in the SAS programs and aids in sinking the amount of text that the programmer must enter to complete tasks.
Macro variables can provide a variety of information to SAS session information to any text string that is defined. By replacing with text into programs, SAS macro variables make your programs easy to update. A macro variable is independent of a SAS data set and restrains one value that remains constant until you change it. The value of a macro variable is always a text string that becomes part of your program whenever the macro variable is referenced.

Types of Macros in Advanced SAS - VirtualNuggets


Types of Macro Variables in Advanced SAS :
Automatic macro variables - provided by SAS software
User-defined macro variables – created by the users

Automatic Macro Variables
Automatic Macro Variables are created whenever programmer invoke the SAS System and these macros provide information such as

  • Date or time a SAS job or session began executing
  • Date or time  of release of SAS software that is running
  • Name of the most recently created SAS data set
  • Abbreviation for the host operating system
User-defined Macro Variables
User-defined macro variables enable you to substitute a wider range of text in your programs because you can control the values of the macro variables.
Example : %LET name=value;
Everything appearing between the equal sign and semicolon is considered part of the macro variable value.

%let removes all leading and trailing blank spaces by default except when in quotes;


Note : For Advanced SAS Online Training Contact VirtualNuggets.com
VirtualNuggets 7813909009338927919

Post a Comment

emo-but-icon

Home item

Blog Archive

Popular Posts

Random Posts

Flickr Photo