neo4j-spatial is an extension of Neo4j containing tools to represent and manipulate complex spatial data types. In this section, we are going to learn about this plugin by importing data on districts in Manhattan and finding points of interest located within each district.
Introducing the neo4j-spatial library
The neo4j-spatial plugin can be installed by downloading the latest release jar from https://github.com/neo4j-contrib/spatial/releases and copying this jar to the plugins directory of your active graph. You then need to restart the graph for the changes to be taken into account. Once this is done, you can check that the spatial plugin is enabled by calling the spatial.procedures() procedure, listing all available procedures within the plugin:
CALL spatial.procedures()
With this plugin, we will be able to do the following:
- Import from well-known geographic data formats such as shapefile
- Use topology operations such as contains...