group dataframe `data` entries by year value of the date in column 'date',data.groupby(data['date'].map(lambda x: x.year))