| africa_network | R Documentation |
A spatial dataset representing a discretized road transport network connecting major African cities and ports. The network combines existing road infrastructure (2,344 edges) with proposed new links (481 edges) identified through network efficiency analysis. Each edge contains distance, travel time, border crossing costs, terrain characteristics, and road upgrade cost estimates.
data(africa_network)
A Simple feature collection (sf object) with 2,825 LINESTRING features and 28 fields:
Integer. Origin node index (1 to 1,377).
Integer. Destination node index (2 to 1,379).
Character. Origin country ISO3 code (49 countries).
Character. Destination country ISO3 code (49 countries).
Numeric. Origin node longitude.
Numeric. Origin node latitude.
Numeric. Destination node longitude.
Numeric. Destination node latitude.
Numeric. Spherical (great-circle) distance in meters.
Numeric. Road distance in meters from OSRM routing.
Numeric. Travel duration in minutes from OSRM routing (NA for proposed links).
Numeric. Average speed in km/h (distance/duration) (NA for proposed links).
Numeric. Number of optimal inter-city routes passing through this edge (NA for proposed links).
Numeric. Sum of population gravity weights from routes using this edge (NA for proposed links).
Numeric. Sum of road-distance-weighted gravity from routes (NA for proposed links).
Numeric. Additional distance for border crossing in meters (0 for domestic links).
Numeric. Total distance including border crossing penalty in meters.
Numeric. Additional time for border crossing in minutes.
Numeric. Total travel time including border crossing in minutes.
Numeric. Hypothetical travel time at 100 km/h in minutes.
Numeric. Hypothetical total time at 100 km/h including border penalties.
Numeric. Terrain ruggedness index along the edge.
Numeric. Population within corridor (WorldPop data).
Numeric. Population density per km2 along corridor.
Numeric. Estimated road construction/maintenance cost per km in USD.
Character. Road upgrade category: "Nothing", "Asphalt Mix Resurfacing", "Mixed Works", "Upgrade", or NA.
Numeric. Upgrade cost per km in USD.
Logical. TRUE for proposed new links, FALSE for existing road network edges.
LINESTRING. Spatial geometry in WGS 84 (EPSG:4326) coordinate reference system.
The network was constructed through the following process:
Computing optimal routes between all city pairs within 2,000km using OSRM
Filtering routes using network efficiency criteria (alpha = 45 degrees, EU-grade efficiency)
Intersecting and aggregating overlapping route segments
Contracting the network to reduce complexity while preserving connectivity
Identifying proposed new links that would improve network route efficiency
Adding border crossing costs based on country pairs
Computing terrain, population, and road cost attributes
The gravity and gravity_rd fields measure edge importance based on the population
gravity model: routes between larger, closer cities contribute more weight to edges they traverse.
The bounding box spans continental Africa from approximately 34S to 37N latitude and 17W to 49E longitude.
Road network derived from OpenStreetMap via OSRM routing. Border crossing data from World Bank estimates. Terrain data from SRTM elevation models. Population data from WorldPop.
Dataset constructed for: Krantz, S. (2024). Optimal Investments in Africa's Road Network. Policy Research Working Paper 10893. World Bank. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1596/1813-9450-10893")}. Replication materials: https://github.com/SebKrantz/OptimalAfricanRoads.
africa_cities_ports, africa_segments,
africa_trade, flownet-package
library(sf)
data(africa_network)
head(africa_network)
# Existing vs proposed links
table(africa_network$add)
# Cross-border links
cross_border <- africa_network[africa_network$from_ctry != africa_network$to_ctry, ]
nrow(cross_border)
# Upgrade categories
table(africa_network$upgrade_cat, useNA = "ifany")
# Plot by gravity
plot(africa_network["gravity_rd"])
# Highlight proposed new links
plot(africa_network[africa_network$add, "geometry"], col = "red", add = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.