momepy.SharedWalls

class momepy.SharedWalls(gdf)[source]

Calculate the length of shared walls of adjacent elements (typically buildings)

\[\textit{length of shared walls}\]

Note that data needs to be topologically correct. Overlapping polygons will lead to incorrect results.

Adapted from [HLM12].

Parameters
gdfGeoDataFrame

GeoDataFrame containing gdf to analyse

See also

SharedWallsRatio

Examples

>>> buildings_df['swr'] = momepy.SharedWalls(buildings_df).series
Attributes
seriesSeries

Series containing resulting values

gdfGeoDataFrame

original GeoDataFrame

__init__(gdf)[source]

Initialize self. See help(type(self)) for accurate signature.

Methods

__init__(gdf)

Initialize self.