Filtering GTFS
Processing the GTFS files before mapping the public transit to the MATSim network
URL
Data reference: https://developers.google.com/transit/gtfs/reference
PID GTFS: https://pid.cz/o-systemu/opendata/
Keeping Urban Routes Only
Filter out routes that are suburban and keep only:
Tram L1-26, night tram L90-L96
Bus L100-L299, night bus L900-L916
Subway L991-L993 (metro A-C)
Funicular L49
Ferry L1801-L1807 (P1-P7)
Running the Filter
Clone the Metacity-MATSim repository
Move into the
utility/gtfs
folderAdd the downloaded (unzipped) GTFS folder into the
utility/gtfs/data
folderRun:
python filter_by_route_id.py data/PID_GTFS/ -o PID_GTFS_filtered/
The filtered GTFS will be in the
utility/gtfs/output
folder by default
Last updated