SAS macro to generate the PDF/Excel/RTF report from the input SAS dataset..,indsn – Input Dataset, varlist – List of Variables to be printed. If none then print all variables in the dataset, report_type – PDF or Excel or RTF, title1 – Title1 of the report footnote1 – Footnote1 of the report report_location – Physical location of the report....
can u help me in building logic for this...?
So what is it "you" have done towards this, what is the "question" you are stuck on. Much like the other posts, this is just a request for someone else to write the program for you.
You can use the below logic to check the VAR Listed under VARS
%Macro ReportGen (indsn=DatasetName, Vars=);
Proc print data = &DatasetName;
%if &vars ne %then %do;
VAR &Vars;
%end;
%else %do;
%put no var specified !!;
%End;
Run;
%Mend ReportGen;
%ReportGen(Admit,)
%ReportGen(Admit, Name Gender)
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.
Find more tutorials on the SAS Users YouTube channel.