BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hi,

My question is how to generate report using predefined template and places where appropriate charts and tables generated with SAS should be placed. I searched lots in the google but unfortunately all the samples was ho to generate RTF using some standardization like font size, colors, etc. But the main my aim is to have a possibility to change some explanatory text near the charts or tables which are generated runing SAS procedures.

Thanks in advance!
3 REPLIES 3
Cynthia_sas
SAS Super FREQ
Hi:
I'm not entirely sure what you mean by a "template" -- a Word .dot file??? With SAS, the term "template" can mean several different things -- you can have a SAS/GRAPH template for use with PROC GREPLAY; there are ODS templates -- table, style, tagset and graph templates; you can have report templates in Web Report Studio or task templates in SAS Enterprise Guide (this is new).

One thing I've done is create a CSV file of data points or variable information and then use the Word mail/merge capability to create the same document for every Region or every BY group, for example -- by using my CSV file as input to the mail merge. This does mean that you have to design the Word document ahead of time and you have to know what the field codes are that Word is expecting to find in the CSV file.

Specifically, to change explanatory text for charts or documents, you might want to investigate the use of ODS RTF TEXT= (for SAS 9.1.3) or ODS TEXT= (for SAS 9.2). The TEXT= option allows you to insert text before and/or after procedures in order to send a simple caption or a paragraph of explanatory text into your ODS RTF result file. When you combine this option with SAS macro variables, you have a very flexible way to insert explanatory text into ODS output files.

cynthia
deleted_user
Not applicable
Thanks for the answer.

"Template" I ment that I have already prebuilded RTF file where i putted special keys and after charts and tables preparation those keys should be replaced by respective charts or tables.
Duong
Obsidian | Level 7
Hi berniunas

I think you are after some thing like in the paper below. Although I have used XML and HTML I have not tried RTF, but it should be the same in principle. You might have to refer to

RTF Pocket Guide: (Sean M. Burke)

for graphics.


http://www.tranz.co.uk/PSI2008_WD_Patient_Profiling.pdf



Duong

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 3 replies
  • 1214 views
  • 0 likes
  • 3 in conversation