Exploring the time geography of public transport networks with gtfs2gps
A while ago, we created
gtfs2gps, an R package that converts public transport data from GTFS format to GPS-like records. After a lot of package improvements, different versions and over 15K downloads on CRAN, we finally have a preprint of the paper that introduces
gtfs2gps to the world. In this paper we explain the methods behind
gtfs2gps and show with a reproducible example how the package can help us understand and visualize the time geography of public transport systems.
- Pereira, R. H. M., Andrade, P. R., & Bazzo, J. P. V. (2022). Exploring the time geography of public transport networks with the gtfs2gps package. SocArXiv preprint https://doi.org/10.31235/osf.io/qydr6.
The creation of the General Transit Feed Specification (GTFS) in the mid-2000s provided a new data format for cities to organize and share digital information on their public transport systems. GTFS feeds store geolocated data on public transport networks, including information on routes, stops, timetables, and service levels. The GTFS standard is now widely adopted by thousands of transport authorities and a wide variety of software applications for different purposes, including trip planning, timetable creation and accessibility analysis. Yet, there is still a lack of tools to parse GTFS data in a way that allows one to analyze the complex spatial and temporal patterns of public transport systems. This paper presents gtfs2gps, a new computational tool to easily process GTFS data that allows one to analyze the space-time trajectories of public transport vehicles at fine spatial and temporal resolutions. gtfs2gps is an open-source R package that employs parallel computing to convert GTFS feeds from relational text files into a data table format similar to GPS records with the timestamps of vehicles in every single trip. This paper explains the package functionalities and demonstrates how gtfs2gps can be used to articulate key concepts in time geography to explore and visualize the spatial and temporal patterns of public transport networks. The paper is accompanied by a computational notebook in R Markdown that allows one to easily reproduce the results in this paper or even replicate the analysis and data visualizations for other contexts where GTFS data is available. Given the widespread use of GTFS by transport agencies, gtfs2gps opens new possibilities for researchers to examine the time geography of public transport systems in urban areas across the globe.
Figure 4: Bundling of space-time paths of routes/trips that arrive at a selected bus stop within a 10-minute window. São Paulo, Brazil.