Skip to main content
100%

Data wrangling for ArcGIS to Cypher

✓ Published0🌍 Public
CCliffordAnderson
Last edited Aug 14, 2014
Created on Aug 14, 2014

This example shows how raw tabular GIS data is wrangled into a node-and-edge format suitable for importing into a graph database like Neo4j via Cypher. It extracts distinct pairs of connected points from an ArcGIS feature table by computing start and stop coordinates from X/Y fields and their offsets, then filters out self-loops where start equals stop. The code uses the XQuery language with the `fn:distinct-values`, `fn:data`, and `string-join` functions to build a comma-separated list of connected node IDs and edge lengths. It explicitly demonstrates the data-cleaning step—removing duplicate or invalid connections—before the result is ready for Cypher’s `LOAD CSV` or `MERGE` commands.

AI-generated description

Similar vizzes