BookmarkSubscribeRSS Feed
Chanzo
Calcite | Level 5


I tried creating some graphs with data tips, based on this example:

Example 1: Adding Custom Data Tips to a Graph in a Web Presentation

SAS/GRAPH(R) 9.3: Reference, Third Edition

I run my program in batch on Windows, SAS 9.3.

Works great - BUT:

  1. It makes me view all the graphs on screen while the program is running. How do I stop it doing that? I just want the files.
  2. It puts all the files in the current directory. I don't want my directory cluttered up with lots of graphics files; how can I get it to create a subdirectory and put them all in there?

I'm sure these things are really simple, but darned if I can figure it out. Can some kind person help?

3 REPLIES 3
ballardw
Super User

I don't have 9.3 but 9.2 has an option reached by using Tools>Option>Preferences>Results , uncheck box "View results as generated"

Remember to turn it back on afterwards!

ODS HTML path sets where your output files are going but if you want the graphics in a folder other than that with the HTML then you'll need to work with other options to ensure the references in the HTML point to that folder.

KarlK
Fluorite | Level 6

For question #2, you want the "gpath=" option on the ODS HTML statement. From the SAS 9.3 ODS User's Guide:

"specifies the location for all graphics output that is generated while the destination is open. Use this option when you want to write graphics output files to a location different that specified by the PATH= option for markup files."


Karl

Chanzo
Calcite | Level 5

Thanks, the GPATH= option on the ODS HTML statement lets me put all the graphics files away in a separate subdirectory.

For the other problem - having to respond while it displays all the graphs on screen, even though running in 'noninteractive' or 'batch' mode:

     GOPTIONS NOPROMPT;

helps, insofar as the graphs just flash by on screen without requiring any user interaction.

I found that if I also specify:

     GOPTIONS DEVICE=HTML;

then I don't even see anything on screen at all, which is great, although then I get a duplicate set of graphics files in (by default) a 'sasgraph' subdirectory (I think that can be changed using the GSFNAME= option).

If I could have

  • no forced user interaction for graphs displayed on screen
  • no graphs flashing by on screen
  • no duplicate output files

that would be perfect. But what I have now is good enough for my purposes.

sas-innovate-wordmark-2025-midnight.png

Register Today!

Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.


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.

SAS Training: Just a Click Away

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

Browse our catalog!

Discussion stats
  • 3 replies
  • 1539 views
  • 3 likes
  • 3 in conversation