[GIS] Getting a list of zip codes with its adjacent zip codes

arcgis-desktopdataunited-states

I need a list in the form of adjacency list that contains all zip codes in the United States that each has a list of adjacent zip codes. I tried searching for it on the internet. Many of them only provide a list, but none of them had a list showing the adjacent list of zip codes. How do I find something like that?

The closest thing I found is a list of counties and their adjacent counties. There are several websites that I believe that they have the information but they are using it for applets like this website, http://www.freemaptools.com/find-zip-codes-inside-radius.htm

If no data is available, could I use the counties list to generate the said list?

EDIT: OP here, I was new to the whole GIS system. I don't know which software to use. I decided to try ArcGIS trial. I downloaded ArcGIS and that .lpk file. But I have no idea how to properly load .lpk in a python script and run PolygonNeighbors_analysis function. ArcPy Documentation and Google are not giving me a clear answer. Can anyone show me how to load .lpk package and use the function? Thanks

EDIT2: I think I should have mentioned that I want that list in a simple .txt file. I think I could do this with ArcPY to collect all zip codes and their neighbors, then store it in the .txt file. My current obstacle to this is that I have no idea how to load .lpk file to ArcPY.

EDIT3: I got it to work! By following what Barrett described, I got a raw .txt file of zip codes and their neighbors. I cleaned it up with my small program. It looks good. Thanks for help!

Best Answer

Get a zip-code boundary layer and run Polygon Neighbors. Review How Polygon Neighbors Works and Up-To-Date Zip-Code Boundaries

Picture below might be different than your ArcMap looks, but the buttons and procedure should be the same.

ArcToolbox Example

Perhaps this is an open-source solution. I have not tested or used this solution which seems to require GRASS 6+ : from the GRASS users mailing list

Daniel Isenegger wrote:

Hi, i work with grass 5.7 having the attribute data in postgres-DB.

in a polygon-shapefile containing several hundred of polygons i want to analyze for each polygon which neighboring polygons it has. Conceptually i see there 2 cases: 1) neighboring polygons sharing a common boundary with the current polygon: these polygons should be selectable by identifying the identifiers of the border-lines of the current polygon and search over all border-lines of all polygons for those identifiers. here my question is: how to identify the identifiers of all border-lines of a polygon?

v.category layer=2 type=boundary to assign cat to boundaries

v.to.db option=sides -p

Related Question