View source: R/convert_stops_to_sf.R
convert_stops_to_sf | R Documentation |
stops
table to simple feature objectConverts the stops
table to a POINT sf
object.
convert_stops_to_sf(gtfs, stop_id = NULL, crs = 4326)
gtfs |
A GTFS object, as created by |
stop_id |
A character vector including the |
crs |
The CRS of the resulting object, either as an EPSG code or as an
|
A POINT sf
object.
# read gtfs
data_path <- system.file("extdata/spo_gtfs.zip", package = "gtfstools")
gtfs <- read_gtfs(data_path)
stops_sf <- convert_stops_to_sf(gtfs)
head(stops_sf)
stops_sf <- convert_stops_to_sf(gtfs, stop_id = "18848")
stops_sf
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.