1df['treat_rate']=df.treats/df.groupby('pet').treats.transform('sum')
2df
3Out[153]:
4 pet treats lbs treat_rate
50 cat 2 5.0 0.25
61 dog 1 9.9 0.50
72 snek 3 1.1 1.00
83 cat 6 4.5 0.75
94 dog 1 9.4 0.50