geopandas.sjoin¶
-
geopandas.
sjoin
(left_df, right_df, how='inner', op='intersects', lsuffix='left', rsuffix='right')¶ Spatial join of two GeoDataFrames.
Parameters: left_df, right_df : GeoDataFrames
how : string, default ‘inner’
The type of join:
- ‘left’: use keys from left_df; retain only left_df geometry column
- ‘right’: use keys from right_df; retain only right_df geometry column
- ‘inner’: use intersection of keys from both dfs; retain only left_df geometry column
op : string, default ‘intersection’
Binary predicate, one of {‘intersects’, ‘contains’, ‘within’}. See http://toblerity.org/shapely/manual.html#binary-predicates.
lsuffix : string, default ‘left’
Suffix to apply to overlapping column names (left GeoDataFrame).
rsuffix : string, default ‘right’
Suffix to apply to overlapping column names (right GeoDataFrame).