Data visualization with SAS programming

How to enlarge or zoom in Proc GMap's maps size(height & width)

Accepted Solution Solved
Reply
Occasional Contributor
Posts: 5
Accepted Solution

How to enlarge or zoom in Proc GMap's maps size(height & width)

Hello there,

I have been drawing some cool maps using PROC GMAP. However, because the map is more detailed to suburbs, it's quiet difficult to make out towns.

I would have loved to just be able to increase or decrease the map size to any scale to fit the view I want. Am thinking there should be an easy way out. I was using width and height in ODS Graphics but I see no effect. Any help?

The Code am using:

/*Filter for the City of Johannesburg*/

DATA SP_SAmaps;

  SET userlib2.SP_SAmaps(where=(DC_MDB_C='JHB'));

Run;

/*Draw-up the MAP*/

ods graphics on /

      width=300in

      height=300in

      imagefmt=gif

      imagemap=on

      imagename="SA_Map"

      border=off;

title1 ls=1.5 "City of Johannesburg";

pattern1 v=s c=white ;

PROC GMAP map=SP_SAmaps data=SP_SAmaps;

  id SP_NAME;

  choro MP_NAME /  discrete NOLEGEND coutline=gray88 ;

RUN;

ods graphics OFF;

Regards,


Accepted Solutions
Solution
‎05-26-2015 09:59 AM
SAS Employee
Posts: 170

Re: How to enlarge or zoom in Proc GMap's maps size(height & width)

There are several ways.  I'm not sure what you are looking for.

First, GOPTION xpixels/ypixels can be used to make the map bigger:

goption xpixels=1000 ypixels=1000;

Next, you can use Proc GPROJECT to "clip" the map in just one area or part of Johannesburg.

So, you are not showing the entire map, but only part of it.

http://support.sas.com/documentation/cdl/en/graphref/63022/HTML/default/viewer.htm#gr23n03-ex.htm

And finally, you can use the JAVA driver to make a map that you can interactively pan and zoom in on.

Go to http://support.sas.com/rnd/papers/#2013 and look for the paper and examples Google-like Maps in SAS.

View solution in original post


All Replies
Solution
‎05-26-2015 09:59 AM
SAS Employee
Posts: 170

Re: How to enlarge or zoom in Proc GMap's maps size(height & width)

There are several ways.  I'm not sure what you are looking for.

First, GOPTION xpixels/ypixels can be used to make the map bigger:

goption xpixels=1000 ypixels=1000;

Next, you can use Proc GPROJECT to "clip" the map in just one area or part of Johannesburg.

So, you are not showing the entire map, but only part of it.

http://support.sas.com/documentation/cdl/en/graphref/63022/HTML/default/viewer.htm#gr23n03-ex.htm

And finally, you can use the JAVA driver to make a map that you can interactively pan and zoom in on.

Go to http://support.sas.com/rnd/papers/#2013 and look for the paper and examples Google-like Maps in SAS.

🔒 This topic is solved and locked.

Need further help from the community? Please ask a new question.

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