SAS Advanced programming 정리- SAS Macro (9)

Hoya Jaeho Lee·2022년 4월 12일
0

SAS Advanced programming

목록 보기
9/17

Chapter 9 - Introducing Macro Variables

Macro 단원 시작!!
교재로 주 공부

symbolgen: specifies the log messages about macro variable references are displayed
nosymbolgen:speficies the log messages about macro variable references are not displayed

Inserting Macro Variables Immediately before Text

%let graphics=g;
%let year=02;
%let month=jan;
%let var=sale;
proc &graphics.chart data=sasuser.y&year&month;
hbar week / sumvar=&var;
run;
proc &graphics.plot data=sasuser.y&year&month;
plot &var*day;

&graphics.매크로변수 후에 .을 찍는 이유 확인;

%nrstr는 특수문자 그대로 인식
%substr, %qsubstr는 특수문자 그대로 인식
%index()는 위치 값 반환
%scan,%qscan

비교해서 확인:)


&lib.. : sasuser.y02~

profile
Biostatistics researcher Github: https://github.com/hoyajhl

0개의 댓글