Groupby in Pandas
Volume_Agent = union.groupby(['YM','AgentID','Channel Name','Invoice Type','Province',
'SR_Territory','SR_Name'
,'Brand_y','Brand Segment','Brand Variants'
,'Pack Type','CH'], as_index=False)[['Total HL','Quantity']].sum()
Volume_Agent = union.groupby(['YM','AgentID','Channel Name','Invoice Type','Province',
'SR_Territory','SR_Name'
,'Brand_y','Brand Segment','Brand Variants'
,'Pack Type','CH'], as_index=False)[['Total HL','Quantity']].sum()
Comments
Post a Comment