I have the following data in a pandas df:
Season | Answer
------ | ------
0 4 | 0
1 4 | 0
2 2 | 0
3 1 | 1
4 4 | 1
5 2 | 1
6 3 | 0
7 1 | 0.5
8 4 | 1
9 4 | 0
I want to count how many days of each season have Answer=1, how many with answer=0.5, and how many with answer=0 to get next result:
Season | Answer | Quantity
------ | ------ | --------
0 4 | 0 | 3
1 4 | 0 | 3
2 2 | 0 | 1
3 1 | 1 | 1
4 4 | 1 | 2
5 2 | 1 | 1
6 3 | 0 | 1
7 1 | 0.5 | 1
8 4 | 1 | 2
9 4 | 0 | 3