print seriesgroupby object code example Example: seriesgroupby object g1['group'].apply(pd.DataFrame)