Defining Defaults (DEFINE-!ENDDEFINE command)
The optional !DEFAULT keyword in the macro definition establishes default settings for arguments.
!DEFAULT. Default argument. After !DEFAULT, specify the value you want to use as a default for that argument. A default can be specified for each argument.
Example
DEFINE macdef (arg1 = !DEFAULT (V1) !TOKENS(1)
/arg2 = !TOKENS(1)
/arg3 = !TOKENS(1))
frequencies variables = !arg1 !arg2 !arg3.
!ENDDEFINE.
macdef arg2=V2 arg3=V3.
- V1 is defined as the default value for argument arg1. Since arg1 is not specified on the macro call, it is set to V1.
- If !DEFAULT (V1) were not specified, the value of arg1 would be set to a null string.