socio4health.Harmonizer.harmonize_dataframes#

Harmonizer.harmonize_dataframes(country_dfs: Dict[str, List[DataFrame]]) Dict[str, List[DataFrame]][source]#

Harmonize Dask DataFrames using the instance parameters.

Parameters:

country_dfs (dict of str to list of dask.dataframe.DataFrame) –

Dictionary mapping country names to lists of Dask DataFrames to be harmonized.

Returns:

Dictionary mapping country names to lists of harmonized Dask DataFrames.

Return type:

dict of str to list of dask.dataframe.DataFrame

Note

  • Column and value mappings are applied per country using the provided configuration.

  • If strict_mapping is enabled, unmapped columns or values will raise a ValueError.

  • Column renaming and categorical value harmonization are performed in-place.