Open ritchie46 opened 3 years ago
https://github.com/r-brink/baby_names_generator/blob/bd9777fcffc375b2e27d840bd87c8044228a58c1/generate_babynames_complete.ipynb#L262
Using this expr makes sure that the column names are restored during an aggregation.
df_nl = df_stacked.groupby('Naam').agg([pl.sum('Aantal').keep_name()])
Thanks, didn't know it existed. Gonna update it
https://github.com/r-brink/baby_names_generator/blob/bd9777fcffc375b2e27d840bd87c8044228a58c1/generate_babynames_complete.ipynb#L262
Using this expr makes sure that the column names are restored during an aggregation.