BookmarkSubscribeRSS Feed
SwissC
Obsidian | Level 7

Is there a way to name SGE files produced in ODS?

 

I have

 
ODS graphics on;
ODS RTF file="C:/Users/SwissC/kmplot.rtf" sge=on;
ODS select SurvivalPlot;
 
PROC LIFETEST data=a PLOTS=survival …...
RUN;
 
ODS graphics off;
ODS RTF close sge=off;

 

Now using the above I get a SGE file called SurvivalPlot_RTF.sge.  Is there a way to get the file named kmplot.sge?  I am sure I could do some rename statements to rename the file but I am not sure if that is allowed on our system.

 

* There are possible syntax errors in the code above as it is not copy and pasted from my SAS session.

2 REPLIES 2
SuzanneDorinski
Lapis Lazuli | Level 10

You can use the IMAGENAME option on the ODS GRAPHICS statement to specify the base name.  SAS then adds an underscore followed by the name of the destination.

 

I used the first PROC LIFETEST in the online documentation example 2 as example code below.  

 

The code below produces kmplot_RTF.sge.  

 

ods graphics on / imagename="kmplot"
                  reset=index;

ODS RTF file="/folders/myfolders/ODS RTF/kmplot.rtf" sge=on;

ODS select SurvivalPlot;

proc lifetest data=sashelp.BMT plots=survival(atrisk=0 to 2500 by 500);
   time T * Status(0);
   strata Group / test=logrank adjust=sidak;
run;

ODS RTF close;

 

SwissC
Obsidian | Level 7

Cheers, but this still results in a SAS supllied suffix I would rather not have.  In any case it is now not an issue as the client will not accept the sge image.

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 678 views
  • 0 likes
  • 2 in conversation