I have data like this
and I want to sum the column in PEMAKAIAN
by same date.
I want output for example like this
Is that possible?
if you do:
import pandas as pd
df = pd.DataFrame({'day': [1, 1, 2, 2], 'PEMAKAIAN': [700.0, 720.0, 700.0, 700.0]})
df2 = df.groupby(['day']).sum().reset_index()
you will get the following df2 dataframe:
day PEMAKAIAN
0 1 1420.0
1 2 1400.0