TransWikia.com

Assign “parcel boundaries” to “census areas” from “MULTIPOLYGON” in GeoPackage file “.gpkg” using Python

Geographic Information Systems Asked on February 3, 2021

In one layer I have “polygons layer” of all “parcel boundaries”, in another layer I have the “polygon” of “census areas”. And I would need to assign every “parcel boundaries” to the “census areas” belongs to. I have a GeoPackage file “.gpkg”. Geometry is in MULTIPOLYGON format. E.g. MULTIPOLYGON (((595568.124 4417209.48, 595563.754 4417209.48, and so on…..)))

Do you know how can assign parcel boundaries to census areas from MULTIPOLYGON format using Python or find more information?
I am reading “.gpkg” file using “geopandas” in Python.

One Answer

Ids were assigned using a Spatial Join from geopandas:

gdf1 = geopandas.sjoin(gdf1, gdf2, how="inner", op='intersects')

Answered by Jessica on February 3, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP