how to group pandas dataframe entries by date in a non-unique column,data.groupby(data['date'].map(lambda x: x.year))