Applications of the DATA Step Graphics Interface

Enhancing Existing Graphs

You can use DSGI to enhance existing graphs. You can add text and other graphics elements. You can also alter the appearance of the existing graph by scaling or reducing it. To enhance a graph produced by a SAS/GRAPH graphics procedure, insert the existing graph into graphics output being generated with DSGI.
To insert a graph, provide the following:
  • the catalog in which the existing graph is located
  • the name of the existing graph
  • the coordinates of the place in the graphics output where you want to insert the existing graph
  • a square coordinate system ((0,0) to (100,100))
  • the statements to draw enhancements to the existing graph
The coordinates that DSGI uses to position existing graphs, enhancements to that graph, or graphics elements are based on units of percent of the window system currently defined. See Using Viewports and Windows.

Creating Custom Graphs

You can produce custom graphs with DSGI without using a data set to produce the graphics output. DSGI enables you to create the following:
  • arcs
  • bars
  • ellipses
  • elliptical arcs
  • lines
  • markers
  • pie slices
  • polygons (filled areas)
  • text
To create custom graphs, provide the folowing:
  • DSGI statements to draw graphics elements
  • the coordinates of the graphics elements in the output
You can also specify the color, pattern, size, style, and position of the graphics elements.