BookmarkSubscribeRSS Feed
CarolineDP
Calcite | Level 5

I'm trying to learn how to use gmap.

Even with a common example using a predefined sas map, I don't see any result and I don't get any error message in the log.

I was trying:

 

proc gmap
map=maps.us
data=maps.us (obs=1)
all;
id state;
choro state / nolegend;
run;

1 REPLY 1
ballardw
Super User

1) it often helps to paste the LOG with any messages

2) Proc Gmap supports run group processing so you want to make sure to end with a QUIT statement so the proc stops.

3) What ods destination was open and what ods style is active?

 

I can run your code and get a US map with Alabama as the only state with color other than background.

The log result:

NOTE: Writing HTML Body file: sashtml1.htm
10   map=maps.us
11   data=maps.us (obs=1)
12   all;
13   id state;
14   choro state / nolegend;
15   run;

NOTE: 77983 bytes written to C:\Users\ballarde\OneDrive -
      IDHW\Data\WORK\SASTemp\_TD6704_CWPP0173_\gmap1.png.
16   quit;

The bits in green show where the results were sent. If you don't have these then look for a "no ods destinations active" note. Or verify that your ODS destination will accept graphics, not all do.

 

sas-innovate-2024.png

📢

ANNOUNCEMENT

The early bird rate has been extended! Register by March 18 for just $695 - $100 off the standard rate.

 

Check out the agenda and get ready for a jam-packed event featuring workshops, super demos, breakout sessions, roundtables, inspiring keynotes and incredible networking events. 

 

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 579 views
  • 0 likes
  • 2 in conversation