View source: R/utils-shapefiles.R
sr_cities_in_district | R Documentation |
Get the cities in a school district and return a dataframe with the cities and their populations.
sr_cities_in_district(district_shapefile, state_abb)
district_shapefile |
The shapefile of the district. Can use |
state_abb |
The two letter state abbbreviation on the state that you want to show all schools for. |
A data frame with all the cities within a district's boundaries and each city's population.
## Not run:
district_shapefile <- tigris::school_districts(state = "AR", cb = FALSE) |>
dplyr::filter(GEOID == "0503060")
sr_table_cities_in_district(district_shapefile, "AR")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.