Summarise based on binary values
0 1 How can I summarize this dataframe. OCT NOV DEC JAN Feb Mar Apr May Jun Jul Aug Sep Total Sales 0 0 0 0 0 1 0 0 0 0 0 0 0 4825379.818 1 0 0 0 0 1 0 0 0 0 0 0 0 5522382.297 2 0 0 0 0 1 0 0 0 0 0 0 0 5721183.289 3 0 0 0 0 1 0 0 0 0 0 0 0 5374047.083 4 0 0 0 0 0 1 0 0 0 0 0 0 4917456.971 I want it to be in form Month Sales JAN 1235 FEB 5454 .. .. .. python pandas share | improve this question asked Nov 11 at 10:28 Ayman Alawin 41 7 add a comment | 0 1 How can I summarize this dataframe. OCT NOV DEC JAN Feb Mar Apr May Jun Jul Aug Sep Total Sales 0 0 0 0 0 1 0 0 0 0 0 0 0 4825379.818 1 0 0 0 0 1 0 0 0 0 0 0 0 5522382.297 2 0 0 0 0 1 0 0 0 0 0 0 0 5721183.289 3 0 0 0 0 1 0 0 0 0 0 0 0 5374047.083 4 0 0 0 0 0 1 0 0 0 0 0 0 4917456.971 I want it to be in form Month Sales JAN 1235 FEB 5454 .. .. .. python pandas share | improve this question asked Nov 11 at 10:28 Ayman Alawin 41 7 add...