The GREPLAY Procedure |
Catalog Entries |
The GREPLAY procedure can perform actions on three types of catalog entries:
store output from SAS/GRAPH procedures. The GREPLAY procedure uses two types of graphics catalogs: the input-catalog and the output-catalog. The input-catalog is the catalog that contains the graphics output that you want to replay. The output-catalog is the catalog in which graphics output that is produced by the template facility is stored. Both of these catalogs are GSEG catalogs. The same GSEG catalog can be used as the input-catalog and the output-catalog.
store templates created with the GREPLAY procedure. The catalog in which template entries are stored is referred to as the template catalog. SAS provides sample templates in SASHELP.TEMPLT. TEMPLATE entries can also be stored in GSEG catalogs.
You can use templates directly from SASHELP.TEMPLT to replay your graphics output, or you can copy these templates to a different catalog and edit the copied entries. Graphics output replayed using a template creates a new GRSEG entry.
store color maps created with the GREPLAY procedure. The catalog in which color map entries are stored is referred to as the color map catalog. CMAP entries can be stored in GSEG catalogs. They can also be stored in other catalogs. You can copy, edit, or use these color maps to replay your graphics output. Graphics output replayed using a color map does not create a GRSEG entry.
You can store all of the previous entry types in a single SAS catalog, or you can store them in separate catalogs and use a different catalog for each type of entry. A single SAS catalog may contain graphics output, color maps, and templates.
Because the GREPLAY procedure operates on catalog entries, you must assign at least one catalog before you perform any tasks. The GREPLAY procedure has several ways to assign catalogs shown in Assigning Catalogs.
Catalog | How to Assign |
---|---|
input | IGOUT= option in the PROC GREPLAY statement |
output | GOUT= option in the PROC GREPLAY statement |
template | TC= option in the PROC GREPLAY statement |
color map | CC= option in the PROC GREPLAY statement |
Note: Image entries can exist in catalogs, but are not recognized by the GREPLAY procedure.
Displaying the List of Templates Provided By SAS/GRAPH |
To write the list of templates stored in SASHELP.TEMPLT to the SAS log, submit the following code:
proc greplay nofs tc=sashelp.templt; list tc; run;
Duplicate Entry Names |
The GREPLAY procedure uses the following naming conventions to prevent duplication of names, or overwriting entries:
For entry names with fewer than eight characters, the procedure adds a numeric suffix to the entry's name. The total number of characters is limited to eight.
For entry names greater than or equal to eight characters, the procedure drops the number of characters needed to add a numeric suffix. The total number of characters is limited to eight. For example, if you copy an entry TITLEONE to a catalog that already contains an entry with that name, the procedure assigns the name TITLEON1 to the copied entry.
Note: The GREPLAY procedure uses the same naming conventions for entries created by the template facility.
Note: See also About Filename Indexing.
Ways to Use the GREPLAY Procedure |
You can view, replay or manage catalog entries in two ways:
by submitting code-based GREPLAY procedure statements. The GREPLAY procedure automatically uses code-based statements if you are running in batch mode or in line mode in a non-windowing environment. See Running the GREPLAY Procedure Using Code-based Statements.
by browsing or editing the fields in the GREPLAY procedure windows (if you are running SAS in a windowing environment). For more information, see Using the GREPLAY Procedure Windows.
If you are in the SAS windowing environment, you can toggle between the windows and code-based statements while you run the GREPLAY procedure.
For more information, see the FS Statement and the NOFS option.
Sizing and Naming Your Graphs for Replay (Best Practice) |
To replay your graphics output using the GREPLAY procedure, it is recommended that you do the following:
Select or create a template to replay your graphs. Determine the size of each panel contained in the template. Define the size of each graph to correspond to the size of a panel contained in the template. Size each graph with GOPTIONS such as the XPIXELS= and YPIXELS= options or the HSIZE= and VSIZE= options. If the graphs that you are replaying are too large for the panels in the template, SAS/GRAPH attempts to resize the images.
Ensure that the GRSEG entry names that you want to replay match the names in your GREPLAY procedure statements. If you run a procedure multiple times without updating your GREPLAY statements, the original output is replayed, not the most current output. See Duplicate Entry Names and Replaying Graphs Into a Template.
Copyright © 2010 by SAS Institute Inc., Cary, NC, USA. All rights reserved.