station_info: Rail Station Information

View source: R/rail-info.R

station_infoR Documentation

Rail Station Information

Description

Returns station location and address information based on a given StationCode. Similar to rail_stations(), but returns data on a given station(s) rather than all stations on a line.

Usage

station_info(StationCode, api_key = wmata_key())

Arguments

StationCode

A character vector of one or more station codes. A separate call is made to the API for each code, do not provide more than 10.

api_key

Subscription key which provides access to this API. Defaults Sys.getenv("WMATA_KEY") via wmata_key().

Format

A tibble 1 row per station with 10 variables:

StationCode

Station code for this station. Use this value in other rail-related APIs to retrieve data about a station.

StationName

Full name for this station, as shown on the WMATA website.

StationTogether

For stations with multiple platforms (e.g.: Gallery Place, Fort Totten, L'Enfant Plaza, and Metro Center), the additional StationCode will be listed here.

LineCodes

Character vector of two-letter abbreviations (e.g.: RD, BL, YL, OR, GR, or SV) served by this station. If the station has an additional platform, the lines served by the other platform are listed in the LineCodes values for the record associated with the StationCode found in StationTogether.

Lat

Latitude.

Lon

Longitude.

Street

Street address (for GPS use).

City

City.

State

State (abbreviated).

Zip

Zip code.

Value

A data frame of stations.

See Also

https://developer.wmata.com/docs/services/5476364f031f590f38092507/operations/5476364f031f5909e4fe3311

Other Rail Station Information: rail_destination(), rail_entrance(), rail_lines(), rail_path(), rail_stations(), rail_times()

Examples

## Not run: 
station_info(StationCode = c("A07", "B07"))

## End(Not run)

metro documentation built on Nov. 2, 2023, 6:06 p.m.