%let name=pacific; filename odsout '.'; /* Split up & re-arrange maps.world, so it's centered on the Pacific, rather than the Atlantic. */ /* ---------------- Manipulate World Map ------------------ */ /* I want a world map with dateline in the middle, rather than prime meridian in the middle... */ /* Reduce density, so it's easier to work with */ data whole_map; set maps.world (where=(density<=1 and cont^=97) drop=x y); /* store unprojected lat/long in y/x, since that's where gproject needs them */ x=long; y=lat; run; /* Use gproject to clip-and-close polygons for left & right side */ proc gproject data=whole_map out=right_map dupok project=none longmin=0 longmax=4; id id; run; proc gproject data=whole_map out=left_map dupok project=none longmin=-4 longmax=0; id id; run; /* Move the right half of the map to the left, and make the segment variables unique, since some segments got split into two. */ data right_map; set right_map; segment=segment+5000; x=x-(3.14159*2); run; data left_map; set left_map; run; /* Put map back together. */ data world_map; set right_map left_map; run; proc gproject data=world_map out=world_map dupok norangecheck project=cylindri; id id; run; goptions device=png; goptions xpixels=1200 ypixels=600; goptions border; ODS LISTING CLOSE; ODS HTML path=odsout body="&name..htm" (title="SAS/Graph Custom World Map, Centered on Pacific") style=htmlblue; goptions gunit=pct htitle=6 htext=4 ftitle="albany amt/bold" ftext="albany amt"; pattern v=s c=burlywood; title1 height=.25in ls=1.5 "Custom World Map, Centered on Pacific"; proc gmap map=world_map data=world_map; id id; choro id / levels=1 nolegend coutline=gray des='' name="&name"; run; quit; ODS HTML CLOSE; ODS LISTING;