fix greenspace and add more schools
This commit is contained in:
parent
3a3e249bdd
commit
9cd2b8849c
4 changed files with 161 additions and 61 deletions
|
|
@ -59,6 +59,8 @@ _AREA_COLUMNS = [
|
|||
# Schools
|
||||
"Good+ primary schools within 5km",
|
||||
"Good+ secondary schools within 5km",
|
||||
"Good+ primary schools within 2km",
|
||||
"Good+ secondary schools within 2km",
|
||||
# Demographics
|
||||
"Median age",
|
||||
]
|
||||
|
|
@ -331,6 +333,8 @@ def _build(
|
|||
"noise_lden_db": "Noise (dB)",
|
||||
"good_primary_5km": "Good+ primary schools within 5km",
|
||||
"good_secondary_5km": "Good+ secondary schools within 5km",
|
||||
"good_primary_2km": "Good+ primary schools within 2km",
|
||||
"good_secondary_2km": "Good+ secondary schools within 2km",
|
||||
"max_download_speed": "Max available download speed (Mbps)",
|
||||
"serious_crime_avg_yr": "Serious crime (avg/yr)",
|
||||
"minor_crime_avg_yr": "Minor crime (avg/yr)",
|
||||
|
|
|
|||
|
|
@ -60,9 +60,14 @@ def main():
|
|||
# Load all postcodes for proximity counting
|
||||
postcodes = arcgis.rename({"lng": "lon"})
|
||||
|
||||
result = count_pois_per_postcode(
|
||||
counts_5km = count_pois_per_postcode(
|
||||
postcodes, schools, radius_km=5, groups=SCHOOL_GROUPS
|
||||
)
|
||||
counts_2km = count_pois_per_postcode(
|
||||
postcodes, schools, radius_km=2, groups=SCHOOL_GROUPS
|
||||
)
|
||||
|
||||
result = counts_5km.join(counts_2km, on="postcode")
|
||||
|
||||
result.write_parquet(args.output)
|
||||
size_mb = args.output.stat().st_size / (1024 * 1024)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue