segregation.inference.simulate_evenness_geo_permutation¶
- segregation.inference.simulate_evenness_geo_permutation(df, group=None, total=None, groups=None)[source]¶
Simulate evenness followed by random permutation of geographic units.
- Parameters:
- df
geopandas.GeoDataFrame
geodataframe with population data to be randomized
- group
str
,optional
name of column on geodataframe that holds the group total (for use with single group indices)
- total
str
,optional
name of column on geodataframe that holds the total population for each unit (for use with single group indices)
- groups
list
,optional
list of columns on input dataframe that hold total population counts for each group of interest
- df
- Returns:
geopandas.GeoDataFrame
geodataframe with evenly distributed population groups