From OpenStreetMap

traffic_casualties_2014

Format

An object of class sf (inherits from tbl_df, tbl, data.frame) with 1652 rows and 3 columns.

Examples

if (FALSE) { stplanr::dl_stats19() ac = stplanr::read_stats19_ac() # 214 mb compressed data ac = ac[!is.na(ac$Latitude), ] ac_few_cols = ac[ c("Accident_Severity", "Longitude", "Latitude", "Date")] ac_sf = sf::st_as_sf(ac_few_cols, coords = c("Longitude", "Latitude")) sf::st_crs(ac_sf) = 4326 bb = stplanr::bb2poly(bb = sf::as_Spatial(traffic)) bb_sf = sf::st_as_sf(bb) traffic_casualties = ac_sf[bb_sf, ] pryr::object_size(traffic_casualties) # 2 MB traffic_casualties_2014 = traffic_casualties[ traffic_casualties$Date > "2014-01-01", ] pryr::object_size(traffic_casualties_2014) # 200 kB usethis::use_data(traffic_casualties_2014) } plot(traffic_casualties_2014$Date, traffic_casualties_2014$Accident_Severity)