Task - Service Accessibility#

In this exercise, you will use buffering and spatial join to determine which houses are located within 15 minutes of essential services (you сan select one or two types of services).

Survey - Self Assesment#

Before starting the task, please complete a short self-assessment survey (under 2 minutes) to see what you’ve learned in this module. It’s identical to the survey you took before.

The survey is supposed to be shown below if not, click here to take the survey

Suggested Workflow#

Step 0: Import libraries#

Don’t forget to import the necessary libraries.

import geopandas as gpd
# more libraries here...

Step 1: Load your datasets#

  • Load a dataset of houses (points) in your study area.

  • Load a dataset of services (points), such as schools, hospitals, or other facilities.

#houses = gpd.read_file("path_to/houses.geojson")
#services = gpd.read_file("path_to/services.geojson")

Step 2: Reproject data to a metric CRS#

To measure distances correctly, reproject your data to an appropriate UTM CRS.

#houses = houses.to_crs(epsg=32636)  # example
#services = services.to_crs(epsg=32636)

Step 3: Create service buffer zones#

  • Use .buffer() to create buffer zones around services.

  • Define the buffer distance that corresponds to 15 minutes (e.g., 1000 m).

#service_buffers = services.buffer(1000)

Step 4: Perform a spatial join#

  • Use gpd.sjoin() to identify which houses fall within the buffer zones.

#houses_near_services = gpd.sjoin(houses, service_buffers, predicate="within")

Step 5: Inspect and summarize results#

  • Count how many houses are within reach of services.

  • Optionally, calculate proportions or group by service type.

#summary = houses_near_services.groupby("service_type").size()

Step 6: Visualize the results#

  • Plot houses within 15 minutes of services in one color and those outside in another.

  • Overlay service buffer zones for context.

#ax = service_buffers.plot(color="lightblue", alpha=0.4)
#houses.plot(ax=ax, color="gray")
#houses_near_services.plot(ax=ax, color="red")

Step 7: Explore and Reflect#

Ask yourself:

  • How many houses are within 15 minutes of services?

  • Which types of services are most accessible? Least accessible?

  • Do accessibility patterns match what you know about the city or neighborhood?

  • How might results change if you used travel time along roads instead of simple buffer distance?