Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

cumulative some by date for each user

df=df.sort_values(['date']).reset_index(drop=True)
df["cum_sale"]=df.groupby(['item'])['sale'].cumsum(axis=0)
Source by sinyi-chou.github.io #
 
PREVIOUS NEXT
Tagged: #cumulative #date #user
ADD COMMENT
Topic
Name
1+6 =