WorldBank-Transport / open-transit-indicators

An open-source tool to support transport agencies in planning and managing public transit systems
GNU General Public License v3.0
44 stars 21 forks source link

Parse direction_id, use in avg. service frequency #659

Closed ddohler closed 9 years ago

ddohler commented 9 years ago

Trips in opposite directions were causing the average service frequency indicator (which is actually headway) to report numbers that were roughly 50% too low when the inbound and outbound trips shared stops as in metro or train service. Bus service was usually not affected because bus stops are usually split between inbound and outbound service when they are on opposite sides of the street. This parses out the direction_id parameter from GTFS feeds, when it exists, and groups the trips by direction_id when calculating the service frequency.

If the direction_id doesn't exist in the gtfs feed, all trips will be grouped together, so if there are opposite direction trips which share the same stop, the service frequency at that stop will be artificially reduced.

Note that user-generated scenarios will not benefit from this change because the scenario editor doesn't have any concept of trip directionality, and therefore all trips will be grouped together.

@moradology may also want to take a look.

ddohler commented 9 years ago

Wrong merge target; closing.