Giter Site home page Giter Site logo

christian-werner / spatial-centrality-pub Goto Github PK

View Code? Open in Web Editor NEW
11.0 2.0 0.0 6.31 MB

Sample implementation of spatial betweenness centrality for transport networks

Home Page: https://doi.org/10.5281/zenodo.8125632

License: MIT License

Python 0.02% Jupyter Notebook 99.98%
mobility network-analysis spatial-networks urban-analytics spatial-centrality

spatial-centrality-pub's Introduction

Spatial Centrality

The code provided in this repository shows an exemplary implementation of spatial betweenness centrality for transport networks.

Abstract

Centrality metrics are essential to network analysis. They reveal important morphological properties of networks, indicating e.g. node or edge importance. Applications are manifold, ranging from biology to transport planning. However, while being commonly applied in spatial contexts such as urban analytics, the implications of the spatial configuration of network elements on these metrics are widely neglected. As a consequence, a systematic bias is introduced into spatial network analyses. When applied to real-world problems, unintended side effects and wrong conclusions might be the result. In this paper, we assess the impact of node density on betweenness centrality. Furthermore, we propose a method for computing spatially normalised betweenness centrality. We apply it to a theoretical case as well as real-world transport networks. Results show that spatial normalisation mitigates the prevalent bias of node density.

You find the original GIScience publication at:

https://doi.org/10.4230/LIPIcs.GIScience.2023.83

Further examples are provided at:

https://doi.org/10.5281/zenodo.8125632

Input data

For the given implementation, we used OpenStreetMap data which was downloaded and preprocessed through NetAScore (https://github.com/plus-mobilitylab/netascore). If you want to run analyses for an own area of interest, you can follow instructions given in the NetAScore repository for generating a custom dataset. We further provide datasets for all example cases of the GIScience publication at https://doi.org/10.5281/zenodo.8125632.

The code

This exemplary implementation of spatial betweenness centrality is based on:

You find the adapted algorithm for centrality computation in algo/centrality.py. All further steps for preparing the dataset, computing spatial coverage of nodes, and for visualising results are provided in a notebook netascore_networkx.ipynb. Additional helper functions are located in algo/net_helper.py.

spatial-centrality-pub's People

Contributors

christian-werner avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

spatial-centrality-pub's Issues

contributing code to pysal/momepy

Hey, congrats on the great work!

I wanted to check with you if you have any interest contributing the implementation to the momepy module of PySAL. We have a set of tools there to work with features representing urban morphology, including traditional centrality measurements on street networks (http://docs.momepy.org/en/stable/user_guide/graph/centrality.html).

I would love to see this work incorporated there, to provide a more feature-complete toolkit to users and additional visibility to your work. Would you be interested in contributing your method?

cc @jGaboardi

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.