04-18-2016 10:23 AM
I need to have a listing of subjects and their treatments by site. I did proc freq by site and got the tables that I need in the results window, but I need them to be outputted in indvidual rtf files so each rtf contains info specific for that site.
Any suggestions on how to go about this would be greatly appreciated!
04-18-2016 10:42 AM
Sounds like you are generating clinical tables? If so check with your company for standards, macros and such like. You can output certain objects that freq creates - you can see what objects are created by:
In the log you will see the objects. You can now save these by:
ods output <object>=<dataset>;
Then you can use that dataset as you want, i.e. proc report and such like. You will want to add titles/footnotes, apply a template, specify filetype etc.
04-18-2016 12:10 PM - edited 04-18-2016 12:13 PM
Have a look at the NEWFILE= option of the ODS RTF statement. This will help you to achieve what you want.
If you need more control on the naming of the RTF files have a look at this blog post http://blogs.sas.com/content/sasdummy/2012/03/20/sas-program-by-processing/ by @ChrisHemedinger This programming pattern can be used over and over.