how we can create optional or required parameters in SAS
macro...
Answers were Sorted based on User's Feedback
Answer / ak
%macro Mtest (mvar);
here its required parameter.
----------------------------------------------
%macro Mtest(mvar1=abc);
.....
sas statements using macro variable mvar1
here mvar1 can be optional while calling macro Mtest
if parameter value is not send then it takes default value
as abc
.....
%mend;
Is This Answer Correct ? | 18 Yes | 1 No |
Answer / sheetal
In macro definition you can create required parameters and
using %let or call symput you can create optional
parameters in sas macro
Is This Answer Correct ? | 2 Yes | 9 No |
how the sas basic syntax style described? : Sas-administrator
What is the difference between INPUT and INFILE ?
what is data governance? : Sas-di
What are the difficulties u faced while doing vital signs table or dataset?
what versions of sas have you used (on which platforms)? : Sas programming
If you have a data set that contains 100 variables, but you need only five of those, what is the code to force SAS to use only those variable?
Explain the purpose of retain statement.
How many versions came upto now in SAS?
how to delete the duplicates by using proc sql?
Give some examples where proc report’s defaults are same as proc print’s defaults?
What is the difference between %local and %global?
How do you read in the variables that you need?