Returns schedules for a given route variant for a given date.
bus_schedule(
RouteID,
IncludingVariations = TRUE,
Date = NULL,
api_key = wmata_key()
)
A data frame with 1 row per trip and 10 variables:
Bus route variant. This can be used in several other bus methods which accept variants.
General direction of the trip (NORTH, SOUTH, EAST, WEST, LOOP, etc.).
Descriptive text of where the bus is headed. This is similar, but not necessarily identical, to what is displayed on the bus.
Scheduled start date and time (UTC) for this trip.
Scheduled end date and time (UTC) for this trip.
Unique trip ID. This can be correlated with the data returned from the schedule-related methods.
7-digit regional ID which can be used in various bus-related
methods. If unavailable, the StopID
will be 0 or NA
Stop name. May be slightly different from what is spoken or displayed in the bus.
Order of the stop in the sequence of StopTimes.
Scheduled departure date and time (UTC) from this stop.
Bus route variant, e.g.: 70, 10A, 10Av1, etc.
Whether or not to include variations if a base
route is specified in RouteID. For example, if B30 is specified and
IncludingVariations
is set to TRUE
(default), data for all variations
of B30 such as B30v1, B30v2, etc. will be returned.
(Optional) Date for which to retrieve route and stop information.
Subscription key which provides access to this API. Defaults
Sys.getenv("WMATA_KEY")
via wmata_key()
.
Data frame containing trip information
Other Bus Route and Stop Methods:
bus_departs()
,
bus_path()
,
bus_position()
,
bus_routes()
,
bus_stops()
if (FALSE) {
bus_schedule("70")
}