dodgr: Distances On Directed GRaphs ("dodgr")

dodgrR Documentation

Distances On Directed GRaphs ("dodgr")

Description

Distances on dual-weighted directed graphs using priority-queue shortest paths. Weighted directed graphs have weights from A to B which may differ from those from B to A. Dual-weighted directed graphs have two sets of such weights. A canonical example is a street network to be used for routing in which routes are calculated by weighting distances according to the type of way and mode of transport, yet lengths of routes must be calculated from direct distances.

The Main Function

  • dodgr_dists(): Calculate pair-wise distances between specified pairs of points in a graph.

Functions to Obtain Graphs

  • dodgr_streetnet(): Extract a street network in Simple Features (sf) form.

  • weight_streetnet(): Convert an sf-formatted street network to a dodgr graph through applying specified weights to all edges.

Functions to Modify Graphs

  • dodgr_components(): Number all graph edges according to their presence in distinct connected components.

  • dodgr_contract_graph(): Contract a graph by removing redundant edges.

Miscellaneous Functions

  • dodgr_sample(): Randomly sample a graph, returning a single connected component of a defined number of vertices.

  • dodgr_vertices(): Extract all vertices of a graph.

  • compare_heaps(): Compare the performance of different priority queue heap structures for a given type of graph.


dodgr documentation built on June 7, 2023, 5:44 p.m.