nswVehicles: Vehicle positions for NSW.

Description Usage Value

View source: R/basics.R

Description

This function fetches position data from the NSW public transport vehicle position API. An API key must be obtained by registering at https://opendata.transport.nsw.gov.au/. The result is parsed with the RProtoBuf package using the Google gtfs-realtime proto. The prototype compiler stuff is initialised at package load. The result can be used to query trip updates as well as extract positions

Usage

1
2
nswVehicles(vehicle_type = c("ferries", "sydneytrains", "buses", "lightrail",
  "nswtrains"))

Value

RProtoBuf message


richardbeare/tRainspotting documentation built on Aug. 28, 2020, 2:36 a.m.