Hi everyone, I'm working on a map that overlays the 2010 Core Based Statistical Areas (CBSAs) with the US county boundaries. I've imported the CBSA shapefiles from the US Census websites and am trying to combine it with the SAS supplied maps.counties dataset. However, when I combine the two I get an error message that says "data system requrested, but value is not on graph 'X', 'Y'. I'm a bit confused about what I have done wrong. When I run proc gmap without the maps.counties overlay. I get the CBSA boundaries. Below is a sample of my code. Thanks! /*Importing ESRI file*/ proc mapimport datafile=usdata out=cbsa10;run; /*restricting CBSA boundaries to continental US*/ data cbsa10b; set cbsa10; state=SUBSTR(NAME10,LENGTH(NAME10)-1,2); if state in ("AK","HI","PR") then delete; run; option mprint; data anno_county; set maps.counties (where=(state not in (02,15,72))); length function color $8; anno_flag=1; xsys='2'; ysys='2'; hsys='3'; when='a'; color='cx00ff00'; size=2.0; if _n_=1 then function='poly'; else function='polycont'; run; data combined; set cbsa10b (drop=state) anno_county; run; data cbsa10b anno_county; set combined; if anno_flag=1 then output anno_county; else output cbsa10b; run; data mydata2; set mydata; if ST in ("AK","HI","PR") then delete; run; proc gmap all data=mydata2 map=cbsa10b all anno=anno_county; id CBSAFP10; choro myvariable / discrete coutline=black; run; quit;
... View more