Dear STATA listers,
I have a bunch of geo coordinates across the US. I want to map these coordinates into the corresponding census tracts, that can be easily done with geoinpoly.
I downloaded tiger tract shapefiles from US census. The shapefiles are available state-wise, I first covert the shapefiles into “coor” and “data” files:
shp2dta using "state_tract_x.shp", genid(_ID) data("data_01.dta") coor("coor_01.dta") replace
After the conversion, I appended state-tract files for the whole country. However, when I use geoinpoly it tells me that my _ID is not unique in data_US.dta file. I believe this might be due to intersecting polygons.
What should I do?
If I try to merge state-tract shapefiles using mergepoly, I am not sure how this can be resolved. I tried to follow the following post:
https://www.statalist.org/forums/for...files-in-stata
But file size might become an issue.
I want both statistical analysis and plotting data for the full country.
Any suggestion/guidance would be helpful.
Thank you.
Lg,
Mg
I have a bunch of geo coordinates across the US. I want to map these coordinates into the corresponding census tracts, that can be easily done with geoinpoly.
I downloaded tiger tract shapefiles from US census. The shapefiles are available state-wise, I first covert the shapefiles into “coor” and “data” files:
shp2dta using "state_tract_x.shp", genid(_ID) data("data_01.dta") coor("coor_01.dta") replace
After the conversion, I appended state-tract files for the whole country. However, when I use geoinpoly it tells me that my _ID is not unique in data_US.dta file. I believe this might be due to intersecting polygons.
What should I do?
If I try to merge state-tract shapefiles using mergepoly, I am not sure how this can be resolved. I tried to follow the following post:
https://www.statalist.org/forums/for...files-in-stata
But file size might become an issue.
I want both statistical analysis and plotting data for the full country.
Any suggestion/guidance would be helpful.
Thank you.
Lg,
Mg
Comment