*annotated data set that im using to get state abbreviations on my state maps;
data maplabel;
length function $ 8;
retain flag 0 xsys ysys '2' hsys '3' when 'a' style "'Albnay'";
set maps.uscenter(drop = long lat);
where fipstate(state) ne 'DC' and fipstate(state) ne 'PR';
function = 'label'; text=fipstate(state); size=2.5; position='5';
if ocean = 'y' then
do;
position = '6'; output;
function = 'move';
flag = 1;
end;
else if flag = 1 then
do;
function = 'draw'; size = .5;
flag = 0;
end;
output;
run;
So i have two different maps one thats more basic and one that has more going on.
basic map where maplabel works and the state abbreviations work... the map is of just states;
proc gmap data=work.zipfilter map=maps.us (where=(statecode in ('CA')));
id statecode;
choro m_obs / annotate = maplabel;
run;
proc gmap data=work.heatmapaverage_data map=work.counties (where=(statecode in ('CA', 'NV', 'AZ', 'UT', 'OR', 'WA', 'MT', 'ND', 'ID', 'WY', 'SD'))) all;
id id;
choro paymentperbene / annotate = maplabel
level = 10
cdefault = royalblue
legend legend1
coutline = black;
run;
*more advanced data set that features the counties of each state;
proc sql;
create table counties as
select c.*, us.idname
from mapsgfk.us_counties as c
left join mapsgfk.us_counties_attr as us
on c.id = us.id;
run;
The proc sql creates the map dataset, counties, from data sas enterprise guide gives us. Unfortunately i cant share my response data set.
Im new to sas and i dont understand what the disconnect is.
why would maplabel work on the first gmap and not on the second gmap.
No errors are given for either maps
Any tips and tricks would help.
Thanks a bunch.
First gmap
Second gmap
I was hoping that the state abbreviations would show on the second map as well