if (FALSE) {
library(dplyr)
nyc_path <- system.file("extdata", "nyc_subway.zip", package = "tidytransit")
nyc <- read_gtfs(nyc_path)
stop_group_distances(nyc$stops)
#> # A tibble: 380 × 6
#> stop_name distances n_stop_ids dist_mean dist_median dist_max
#>
#> 1 86 St 18 5395. 5395. 21811.
#> 2 79 St 6 19053. 19053. 19053.
#> 3 Prospect Av 6 18804. 18804. 18804.
#> 4 77 St 6 16947. 16947. 16947.
#> 5 59 St 6 14130. 14130. 14130.
#> 6 50 St 9 7097. 7097. 14068.
#> 7 36 St 6 12496. 12496. 12496.
#> 8 8 Av 6 11682. 11682. 11682.
#> 9 7 Av 9 5479. 5479. 10753.
#> 10 111 St 9 3877. 3877. 7753.
#> # … with 370 more rows
}
Run the code above in your browser using DataLab