不是高手.妄言两句:
1.- The fiction of "CALL SYMPUT (MV, value)" is to assign a value to a macro variable DURING THE EXECUTION OF A DATA STEP.
2.- Macros consist of collections of regular SAS program statements, macro variables, macro language statements, and macro functions contained within a %MACRO and a %MEND
SO:
3. - 第一个例子test, 因为CALL SYMPUT 在regular SAS step中,故会创建X宏变量,
4. - 但第二个例子test1, CALL SYMPUT 在macro language statements(%DO..%END)中, 故不会创建Y宏变量
The above is my understanding, which is maybe incorrect. - just for your ref.
|