Chapter Contents


The GMAP Procedure

Example 1: Producing a Simple Block Map

Procedure features:
ID statement
BLOCK statement option:
Sample library member: GR19N01


This example produces a block map that shows the total number of hazardous waste sites in each state in 1997. Since the DISCRETE option is not used, the response variable is assumed to have a continuous range of values. Because neither the LEVELS= nor MIDPOINTS= option is used, the GMAP procedure selects a number of levels based on the number of map areas and then calculates the appropriate response levels. The legend shows the midpoint value of each level.

The blocks use the default pattern, which is a solid fill that rotates through the colors list. Because the colors list is specified in the GOPTIONS statement, all colors are used in the rotation. CBLKOUT= outlines the blocks in black, instead of using the default outline color, which is the first color in the list- in this case, BLUE.

The map areas use the default pattern for map areas in a block map. This is the first hatch pattern for maps, M2N0. By default, both the fill and the outline use the first color in the colors list.
 Note about code
libname reflib 'SAS-data-library';
libname maps 'SAS-data-library';
goptions reset=global gunit=pct border cback=white
         colors=(blue green lime lipk cyan red)
         ctext=black ftext=swiss htitle=6 htext=3;
 Note about code
data reflib.sites;
   length stcode $ 2;
   input region stcode $ sites;
6   AR  12
10  AK  7...moredata lines...
3   WV  6
8   WY  3
 Note about code
title1 'Hazardous Waste Site Installations (1997)';
footnote1 j=r 'GR19N01 ';
 Note about code
proc gmap data=reflib.sites;
   id state;
   block sites / cblkout=black;

Chapter Contents



Top of Page

Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.