I am new to pandas. I have a large dataset which consists the temperature value on daily wise. I need to compute the temp by monthly wise i.e.
Here my dataset csv structure:
I need to convert into following csv structure:
I was thinking about the following approach:
for(year=2012;year<=2018;year++)
for(month=1;month<=12;month++)
for(day=1;day<=31;day++)
summax+=Temp_max[day]
summin+=Temp_min[day]
summax/=day
summin/=day
print(summax,summin)
But I dont know how to do it in pandas/python, how to fetch the column value in loop, also how to handle the feb days (like 28 days, 30 days, 31 days) and bring the expected output or similar output. Any help would be appreciated. Thanks!!