diff --git a/aif360/algorithms/preprocessing/optim_preproc_helpers/data_preproc_functions.py b/aif360/algorithms/preprocessing/optim_preproc_helpers/data_preproc_functions.py index 11e0b296..3d3fd278 100644 --- a/aif360/algorithms/preprocessing/optim_preproc_helpers/data_preproc_functions.py +++ b/aif360/algorithms/preprocessing/optim_preproc_helpers/data_preproc_functions.py @@ -10,7 +10,7 @@ def custom_preprocessing(df): """ # Group age by decade - df['Age (decade)'] = df['age'].apply(lambda x: x//10*10) + df['Age (decade)'] = df['age'].astype(int).apply(lambda x: x//10*10) # df['Age (decade)'] = df['age'].apply(lambda x: np.floor(x/10.0)*10.0) def group_edu(x):