Docstring yay
Project description
edge_gravity
Function that calculates Edge Gravity as described in: Helander, M.E. & McAllister, S. Appl Netw Sci (2018) 3: 7. https://doi.org/10.1007/s41109-018-0063-6
The k-shortest-paths algorithm stems from:
Jin Y. Yen, "Finding the K Shortest Loopless Paths in a
Network", Management Science, Vol. 17, No. 11, Theory Series
(Jul., 1971), pp. 712-716
It utilizes multiple cores, only tested on Linux.
Parameters
----------
g: NetworkX DiGraph
k: non-negative Integer that describes the maximum number of shortest
path to consider per node.
weight: gets passed to networkx.shortest_simple_paths - for a detailed description
see the docstring of this function.
Returns
----------
A 2-tuple where
the first element is either kstar or False if kstar is not known
the second element is a collections.Counter object with edges as keys and the number of paths as values
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
edge_gravity-0.0.4.tar.gz
(65.3 kB
view hashes)
Built Distribution
Close
Hashes for edge_gravity-0.0.4-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2b3e9119ec03055420e17130c872e9f3d1ab27182c0b412f51b720585747ce10 |
|
MD5 | 31e9ea853fb08f937ccdb956115cd7f2 |
|
BLAKE2b-256 | 94f125ecd77d4f9648cebfe27b09868a9bd014e25057f8270622c539a11e4434 |