Skip to main content

Pandas Network Analysis - dataframes of network queries, quickly

Project description

Build Status Coverage Status

A nice slideshow showing example code is available here.

In this case, a picture is worth a thousand words. The image below shows the distance to the 2nd nearest restaurant (rendered by matplotlib) for the city of San Francisco. With only a few lines of code, you can grab a network from OpenStreetMap, take the restaurants that users of OpenStreetMap have recorded, and in about half a second of compute time you can get back a Pandas Series of node_ids and computed values of various measures of access to destinations on the street network.

Distance to Restaurants

Distance to Restaurants

Beyond simple access to destination queries, this library also implements more general aggregations along the street network (or any network). For a given region, this produces hundreds of thousands of overlapping buffer queries (still performed in less than a second) that can be used to characterize the local neighborhood around each street intersection. The result can then be mapped, or assigned to parcel and building records, or used in statistical models as we commonly do with UrbanSim. This is in stark contrast to the arbitrary non-overlapping geographies ubiquitous in GIS. Although there are advantages to the GIS approach, we think network queries are a more accurate representation of how people interact with their environment.

We look forward to creative uses of a general library like this - please let us know when you think you have a great use case with the hashtag #synthicity.

Docs

Documentation for Pandana is now available.

Thorough API documentation for Pandana is also available.

Acknowledgments

None of this would be possible without the help of Dennis Luxen (now at MapBox) and his OSRM (https://github.com/DennisOSRM/Project-OSRM). Thank you Dennis!

Nearest neighbor queries are performed with the fastest k-d tree around, i.e. ANN (http://www.cs.umd.edu/~mount/ANN/).

Academic Literature

I’m currently working on getting a complete description of the methodology published in an academic journal. Please cite this paper when referring to the methodology implemented by this library.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

pandana-0.1.2.zip (138.4 kB view hashes)

Uploaded Source

pandana-0.1.2.tar.gz (94.1 kB view hashes)

Uploaded Source

Built Distributions

pandana-0.1.2-cp27-none-win_amd64.whl (129.5 kB view hashes)

Uploaded CPython 2.7 Windows x86-64

pandana-0.1.2-cp27-none-win32.whl (92.6 kB view hashes)

Uploaded CPython 2.7 Windows x86

pandana-0.1.2-cp27-none-macosx_10_9_x86_64.whl (109.2 kB view hashes)

Uploaded CPython 2.7 macOS 10.9+ x86-64

pandana-0.1.2-cp27-none-macosx_10_5_x86_64.whl (112.0 kB view hashes)

Uploaded CPython 2.7 macOS 10.5+ x86-64

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page