HOW TO

Find out what polygons are adjacent to other polygons or create an adjacency matrix

Last Published: October 1, 2025

Summary

A matrix is a table that provides values for all row/column combinations. An adjacency matrix is a matrix that indicates whether features are or are not adjacent, or sharing edges.

Procedure

While Esri does not have a tool that directly creates adjacency matrices, there is a tool called Polygon Neighbors. This tool creates a table with a row for every shared edge in a dataset. The tool can also output values such as the total length of the shared edge and the number of vertices shared. This helps a user understand if adjacent polygons are sharing just an edge, or just vertices (for example, a corner to a corner). The user can then use this output and create custom Python code to create an adjacency matrix as needed.

Article ID: 000014890

Software:
  • ArcGIS Desktop

Get support with AI

Resolve your issue quickly with the Esri Support AI Chatbot.

Start chatting now

Related Information

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Start chatting now

Go to download options