dataframe to dictionary of lists of columns with groupby code example Example: convert pandas group to dict res = dict(tuple(d.groupby('a')))