geosnap.analyze.segdyn.singlegroup_tempdyn

geosnap.analyze.segdyn.singlegroup_tempdyn(gdf, group_pop_var=None, total_pop_var=None, time_index='year', n_jobs=-1, backend='loky', **index_kwargs)[source]

Batch compute singlegroup segregation indices for each time period in parallel.

Parameters:
gdfgeopandas.GeoDataFrame

geodataframe formatted as a long-form timeseries

group_pop_varstr

name of column on gdf containing population counts for the group of interest

total_pop_varstr

name of column on gdf containing total population counts for the unit

time_indexstr

column on the dataframe that denotes unique time periods, by default “year”

n_jobsint, optional

number of cores to use for computation. If -1, all available cores will be used, by default -1

backendstr, optional

computation backend passed to joblib. One of {‘multiprocessing’, ‘loky’, ‘threading’}, by default “loky”

Returns:
geopandas.GeoDataFrame

dataframe with unique segregation indices as rows and estimates for each time period as columns