-
Notifications
You must be signed in to change notification settings - Fork 214
Clarify definition of "frequency-based" trips #47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -48,7 +48,7 @@ This specification defines the following files along with their associated conte | |||||||||||||
| | [fare_attributes.txt](#fare_attributestxt) | Optional | Fare information for a transit organization's routes. | | ||||||||||||||
| | [fare_rules.txt](#fare_rulestxt) | Optional | Rules for applying fare information for a transit organization's routes. | | ||||||||||||||
| | [shapes.txt](#shapestxt) | Optional | Rules for drawing lines on a map to represent a transit organization's routes. | | ||||||||||||||
| | [frequencies.txt](#frequenciestxt) | Optional | Headway (time between trips) for routes with variable frequency of service. | | ||||||||||||||
| | [frequencies.txt](#frequenciestxt) | Optional | Trips with variable frequency of service based on a headway (estimated time between trips) or headway-defined schedules. | | ||||||||||||||
| | [transfers.txt](#transferstxt) | Optional | Rules for making connections at transfer points between routes. | | ||||||||||||||
| | [feed_info.txt](#feed_infotxt) | Optional | Additional information about the feed itself, including publisher, version, and expiration information. | | ||||||||||||||
|
|
||||||||||||||
|
|
@@ -379,20 +379,25 @@ Shapes describe the physical path that a vehicle takes, and are defined in the f | |||||||||||||
|
|
||||||||||||||
| File: **Optional** | ||||||||||||||
|
|
||||||||||||||
| This table is intended to represent schedules that don't have a fixed list of stop times. When trips are defined in frequencies.txt, the trip planner ignores the absolute values of the **arrival_time** and **departure_time** fields for those trips in [stop_times.txt](#stop_timestxt). Instead, the **stop_times** table defines the sequence of stops and the time difference between each stop. | ||||||||||||||
| This table is used to represent two types of transit service: | ||||||||||||||
|
|
||||||||||||||
| * frequency-based trips - Service that does not have a schedule of stop times (**exact_times** is **0** or **empty**). Instead, operators make their best effort to serve stops periodically based on a headway. For example, a rider can expect a bus to depart approximately every 15 minutes, but the vehicle will not attempt to adhere to a preset scheduled departure time such as 10:00 am. Therefore, in the absence of real-time information, every subsequent departure is expected with a interval of **headway_secs** from the most recent departure. | ||||||||||||||
| * headway-defined schedules - Service that adheres to a schedule (**exact_times** is **1**). This table can be used to represent simple scheduled service based on a fixed interval without fully listing out all scheduled trips via the [trips.txt](#tripstxt) and [stop_times.txt](#stop_timestxt) files. Instead, the scheduled start time is defined in this table along with the set time between each departure (i.e., headway). Consumers will then expand this to represent scheduled service as if each of these trips were defined in [trips.txt](#tripstxt) and [stop_times.txt](#stop_timestxt). | ||||||||||||||
|
|
||||||||||||||
| When trips are defined in frequencies.txt, the trip planner ignores the absolute values of the **arrival_time** and **departure_time** fields for those trips in [stop_times.txt](#stop_timestxt). Instead, the **stop_times** table defines the sequence of stops and the time difference between each stop. | ||||||||||||||
|
|
||||||||||||||
| | Field Name | Required | Details | | ||||||||||||||
| | ------ | ------ | ------ | | ||||||||||||||
| | trip_id | **Required** | The **trip_id** contains an ID that identifies a trip on which the specified frequency of service applies. Trip IDs are referenced from the [trips.txt](#tripstxt) file. | | ||||||||||||||
| | start_time | **Required** | The **start_time** field specifies the time at which the first vehicle departs from the first stop of the trip with the specified frequency. The time is measured from "noon minus 12h" (effectively midnight, except for days on which daylight savings time changes occur) at the beginning of the service day. For times occurring after midnight, enter the time as a value greater than 24:00:00 in HH:MM:SS local time for the day on which the trip schedule begins. E.g. 25:35:00. | | ||||||||||||||
| | end_time | **Required** | The **end_time** field indicates the time at which service changes to a different frequency (or ceases) at the first stop in the trip. The time is measured from "noon minus 12h" (effectively midnight, except for days on which daylight savings time changes occur) at the beginning of the service day. For times occurring after midnight, enter the time as a value greater than 24:00:00 in HH:MM:SS local time for the day on which the trip schedule begins. E.g. 25:35:00. | | ||||||||||||||
| | trip_id | **Required** | The **trip_id** contains an ID that identifies a trip on which the specified headway of service applies. Trip IDs are referenced from the [trips.txt](#tripstxt) file. | | ||||||||||||||
| | start_time | **Required** | The **start_time** field specifies the time at which the first vehicle departs from the first stop of the trip with the specified headway. The time is measured from "noon minus 12h" (effectively midnight, except for days on which daylight savings time changes occur) at the beginning of the service day. For times occurring after midnight, enter the time as a value greater than 24:00:00 in HH:MM:SS local time for the day on which the trip schedule begins. E.g. 25:35:00. | | ||||||||||||||
| | end_time | **Required** | The **end_time** field indicates the time at which service changes to a different headway (or ceases) at the first stop in the trip. The time is measured from "noon minus 12h" (effectively midnight, except for days on which daylight savings time changes occur) at the beginning of the service day. For times occurring after midnight, enter the time as a value greater than 24:00:00 in HH:MM:SS local time for the day on which the trip schedule begins. E.g. 25:35:00. | | ||||||||||||||
| | headway_secs | **Required** | The **headway_secs** field indicates the time between departures from the same stop (headway) for this trip type, during the time interval specified by **start_time** and **end_time**. The headway value must be entered in seconds. | | ||||||||||||||
| | | | Periods in which headways are defined (the rows in frequencies.txt) shouldn't overlap for the same trip, since it's hard to determine what should be inferred from two overlapping headways. However, a headway period may begin at the exact same time that another one ends, for instance: | | ||||||||||||||
| | | | `A, 05:00:00, 07:00:00, 600` | | ||||||||||||||
| | | | `B, 07:00:00, 12:00:00, 1200` | | ||||||||||||||
| | exact_times | Optional | The **exact_times** field determines if frequency-based trips should be exactly scheduled based on the specified headway information. Valid values for this field are: | | ||||||||||||||
| | | |* **0** or **(empty)** - Frequency-based trips are not exactly scheduled. This is the default behavior. | | ||||||||||||||
| | | |* **1** - Frequency-based trips are exactly scheduled. For a frequencies.txt row, trips are scheduled starting with trip_start_time = start_time + x * headway_secs for all x in (0, 1, 2, ...) where trip_start_time < end_time. | | ||||||||||||||
| | exact_times | Optional | The **exact_times** field determines if trips represent frequency-based service or scheduled-based service using on the specified headway information. Valid values for this field are: | | ||||||||||||||
| | | |* **0** or **(empty)** - Trips are frequency-based. Operators make their best effort to serve stops periodically based on a headway, but there is no fixed schedule. This is the default behavior. | | ||||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @barbeau What do you think about adding an extra note in here to specify expectations around a UI? Or is this superfluous? Proposed additions are in bold italic.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah, that's not a bad idea. It helps shape expectations of how the information is used by consumers. I'll work on tweaking this. |
||||||||||||||
| | | |* **1** - Trips are scheduled. For a frequencies.txt row, trips are scheduled starting with trip_start_time = start_time + x * headway_secs for all x in (0, 1, 2, ...) where trip_start_time < end_time. | | ||||||||||||||
| | | | The value of **exact_times** must be the same for all frequencies.txt rows with the same **trip_id**. If **exact_times** is 1 and a frequencies.txt row has a **start_time** equal to **end_time**, no trip must be scheduled. When **exact_times** is 1, care must be taken to choose an **end_time** value that is greater than the last desired trip start time but less than the last desired trip start time + **headway_secs**. | | ||||||||||||||
|
|
||||||||||||||
| ### transfers.txt | ||||||||||||||
|
|
||||||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am having trouble with the term "headway-defined schedules" for service that adheres to a schedule (exact_times is 1). I keep thinking about "headway" as particularly meaningful because of its context with customers. i.e.. "Service every 10 minutes" shows how headway is presents a "schedule" in customer-facing context. (exact_times = 0).
In transit operations, the similar term "headway-based" seems to often indicate the absence of an exact schedule. Or, at least appeared to, based on a Google search:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I'm not in love with "headway-defined schedule" either - I'm open to proposals for how to name exact_times=1 service. "Headway" can definitely be associated with frequency-based service, but unfortunately we're stuck with the field name
headway_secsfor both types of service. The main rule is that we can't use the word "frequency" for exact_times=1, and we can't use "schedule" for exact_times=0.