- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Is there any way I can save several proc freq and proc contents output tables together (like an log file)? For example:
proc freq data=a; table b c; run;
proc freq data=a1; table b1 c1; run;
proc contents data=a3; run;
I would like to open the saved tables in SAS. Like open an saved log file? Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
I would suggest creating document such as RTF or PDF using ods.
ods rtf file='c:\path\myoutput.rtf'; proc freq data=a; table b c; run; proc freq data=a1; table b1 c1; run; proc contents data=a3; run; ods rtf close;
While those procedures can create output data sets and they could be combined the result would be ugly at best and practically unusable for almost anything. The above code creates a document that most word processors can open for your reading enjoyment. Change the path and file name to what ever you want.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
You have several output options, within SAS and outside.
You can use ODS to have the results sent to PDF, RTF (word), XLSX, PPTX, HTML and some other options.
Or you can capture the data into tables and use those.
If you're looking for the latter, use the OUT= on the TABLE statement and PROC CONTENTS.
If the first, then use something like the following:
ods pdf file='path to file.pdf';
Your sas code goes here;
ods pdf close;
@SSH2 wrote:
Is there any way I can save several proc freq and proc contents output tables together (like an log file)? For example:
proc freq data=a; table b c; run;
proc freq data=a1; table b1 c1; run;
proc contents data=a3; run;
I would like to open the saved tables in SAS. Like open an saved log file? Thank you