Load pre-calcualted trip and distance matrices for a given city, ensuring that all row and column names match.

dd_get_tripdistmats(city, osm = TRUE)

Arguments

city

City for which matrices are to be extracted

osm

If FALSE, return straight-line distances, otherwise street network distances.

Value

List of two square matrices of (i) numbers of trips ($trip) and (ii) distances ($dist) between all stations for nominated city.

Note

The directory from which trip matrices are loaded can be retrieveed with dd_get_data_dir, and set with dd_set_data_dir.