GTFShift

An R tool to assist bus lane prioritization using GTFS and OSM data

GonΓ§alo Matos, Rosa FΓ©lix, Filipe Moura

Bus lanes

Motivation

Limit impacts of congestion
(Cesme et al. 2018)

Reducing travel time variability
(Surprenant-Legault and El-Geneidy 2011)

Increase commercial speed
(Basso et al. 2011)

Other modes can loose
quality of service
(Arasan and Vedagiri 2010)

Potential to jeopardize
public acceptance
(Batty, Palacin, and GonzΓ‘lez-Gil 2014)

It is crucial to underlie these interventions on data and evidence to ensure they are effective and accepted by the public

Criteria

Bus frequency 🚍

Number of lanes πŸ›£οΈ

Traffic conditions πŸš—

Network continuity 🌐

What if we could analyse these dimensions altogether in an open and reproducible way?

Data sources

Bus frequency 🚍
General Transit Feed Specification (GTFS)

Traffic conditions πŸš—
GTFS Real Time (GTFS-RT)

Number of lanes πŸ›£ / Network continuity 🌐
OpenStreetMap (OSM)

Methodology | Bus frequency 🚍 with GTFS

Initial approach: Overline route frequencies to aggregate overlapping values

GTFShift::get_route_frequency_hourly

GTFShift::get_route_frequency_hourly(overline=TRUE)

Methodology | Bus frequency 🚍 with GTFS

Initial approach: Overline route frequencies to aggregate overlapping values

1st challenge: Shapes have distinct geometries, leading to inconsistent results

GTFShift::get_route_frequency_hourly(overline=TRUE)

Methodology | Bus frequency 🚍 with GTFS

Initial approach: Overline route frequencies to aggregate overlapping values

1st challenge: Shapes have distinct geometries, leading to inconsistent results

2nd challenge: Shapes don’t match OSM geometries

Methodology | Bus frequency 🚍 with GTFS and OSM

2nd approach: Use OSM routes geometry to aggregate routes frequency

GTFShift::get_route_frequency_hourly

GTFShift::osm_shapes_match_routes

GTFShift::get_way_frequency_hourly

Methodology | Nr of lanes πŸ›£ / Network continuity 🌐 with OSM

Approach: Get road network topology from OSM

osmdata::opq

GTFShift::osm_bus_lanes

Methodology | Traffic conditions πŸš— with GTFS-RT and OSM

Approach: Compute speed per OSM road segment

GTFShift::rt_collect

sf::st_buffer

GTFShift::rt_extend_prioritization

Methodology | Wrap up

GTFShift::get_way_frequency_hourly

Bus frequency 🚍

Number of lanes πŸ›£

osmdata::opq

GTFShift::osm_bus_lanes

Network continuity 🌐

Traffic conditions πŸš—

GTFShift::rt_extend_prioritization

What if we could analyse these dimensions altogether in an βœ… open and reproducible way?

What if we could analyse these dimensions altogether in an βœ… open and reproducible way?

Reproducibility

πŸ“¦ Open source R package

πŸ“Š Comprehensive framework for bus lane prioritization

πŸ”Ž Provides methods for the analysis of each individual dimension

πŸš€ Enables aggregated analysis with one simple method

Reproducibility

πŸš€ Enables aggregated analysis with one simple method

library(GTFShift)

gtfs = GTFShift::load_feed("https://gateway.carris.pt/gateway/gtfs/api/v2.8/GTFS")

osm_q = opq(bbox=sf::st_bbox(tidytransit::shapes_as_sf(gtfs$shapes)))  |>
  add_osm_feature(key = "route", value = c("bus", "tram")) |>
  add_osm_feature(key = "network", value = "Carris", key_exact = TRUE)

#  Bus frequency 🚍,  Number of lanes πŸ›£οΈ,  Network continuity 🌐 
lanes = GTFShift::prioritize_lanes(gtfs, osm_q)

rt_collection = read.csv("rt_collect_file.csv") |> 
  sf::st_as_sf(coords = c("vehicle.position.longitude", "vehicle.position.latitude"), crs = 4326)

#  Traffic conditions πŸš— 
lanes = GTFShift::rt_extend_prioritization(
  lane_prioritization = lanes,
  rt_collection = rt_collection
)

Output

Carris, Lisbon

Output

Lisbon Metropolitan Area
Carris + Carris Metropolitana

Output

Lisbon Metropolitan Area
Carris + Carris Metropolitana

What if we could analyse these dimensions altogether in an βœ… open and βœ… reproducible way?

What if we could analyse these dimensions altogether in an βœ… open and βœ… reproducible way?

What if we could make it accessible to everyone, without requiring coding skills?

ushift.pt/apps/gtfshift

Interactive dashboard to disseminate results

Future work

Keep contributing to OSM

Extend methods to evaluate operational performance

Apply methodology to international case studies

Write a paper

Thank you!

GTFShift

An R tool to assist bus lane prioritization using GTFS and OSM data

GonΓ§alo Matos, Rosa FΓ©lix, Filipe Moura

References

Arasan, V. Thamizh, and P. Vedagiri. 2010. β€œStudy of the impact of exclusive bus lane under highly heterogeneous traffic condition.” Public Transport 2 (1-2): 135–55. https://doi.org/10.1007/s12469-010-0021-x.
Basso, Leonardo J., CristiΓ‘n Angelo Guevara, Antonio Gschwender, and Marcelo Fuster. 2011. β€œCongestion pricing, transit subsidies and dedicated bus lanes: Efficient and practical solutions to congestion.” Transport Policy 18 (5): 676–84. https://doi.org/10.1016/j.tranpol.2011.01.002.
Batty, Paul, Roberto Palacin, and Arturo GonzΓ‘lez-Gil. 2014. β€œChallenges and opportunities in developing urban modal shift.” Travel Behaviour and Society 2 (2): 109–23. https://doi.org/10.1016/j.tbs.2014.12.001.
Cesme, Burak, Richard Roisman, Ramona Burns, Katie List, Arrianna Koudounas, Jesus Cuellar, Meredyth Sanders, Kevin Lee, and David Miller. 2018. β€œStrategies and Barriers in Effective Bus Lane Implementation and Management: Best Practices for Use in the Greater Washington, D.C. Region.” Transportation Research Record: Journal of the Transportation Research Board 2672 (8): 29–40. https://doi.org/10.1177/0361198118791914.
Surprenant-Legault, Julien, and Ahmed M. El-Geneidy. 2011. β€œIntroduction of reserved bus lane.” Transportation Research Record Journal of the Transportation Research Board 2218 (1): 10–18. https://doi.org/10.3141/2218-02.