Chapter Contents |
Previous |
Next |
The GPROJECT Procedure |
Procedure features: |
| |
Other features: |
| |
Sample library member: | GR23N01 |
Map before Projection (GR23N01(a))
Map before Projection (GR23N01(a)) illustrates the output produced the REFLIB.US48 map data set, which contains only unprojected values, X and Y. The REFLIB.US48 Data Set shows the variables in the data set.
US48 Data Set OBS STATE SEGMENT DENSITY X Y 1 1 1 3 1.48221 0.56286 2 1 1 3 1.48226 0.56234 3 1 1 3 1.48304 0.56231 . . . |
The GPROJECT procedure is used with the REFLIB.US48 map data set as input to create the projected map data set, REFLIB.US48PROJ. The values for X and Y in this new data set are projected (cartesian). The REFLIB.US48PROJ Data Set shows the variables in the data set.
US48PROJ Data Set OBS X Y DENSITY STATE SEGMENT 1 0.16068 -0.073470 3 1 1 2 0.16069 -0.073993 3 1 1 3 0.16004 -0.074097 3 1 1 . . . |
The new projected map data set, REFLIB.US48PROJ, is used to create the projected map, Map after Projection (GR23N01(b)).
Map after Projection (GR23N01(b))
libname reflib 'SAS-data-library'; libname maps 'SAS-data-library'; goptions reset=global gunit=pct border cback=white colors=(black blue green red) ftext=swiss htitle=6 htext=3; |
data reflib.us48; set maps.states; if state ne 2 and state ne 15 and state ne 72; if density<4; run; |
title 'United States Map'; footnote j=r 'GR23N01(a) '; |
pattern value=mempty repeat=50 color=blue; |
proc gmap map=reflib.us48 data=reflib.us48 all; id state; choro state / nolegend; run; |
proc gproject data=reflib.us48 out=reflib.us48proj; id state; run; |
footnote j=r 'GR23N01(b) '; |
proc gmap map=reflib.us48proj data=reflib.us48proj all; id state; choro state / nolegend; run; quit; |
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.