I have a pandas data frame like
date hour level
0 2015-10-27 0 2.5
1 2015-10-27 1 2.5
2 2015-10-27 2 2.5
3 2015-10-27 3 2.5
4 2015-10-28 0 0.0
5 2015-10-28 1 0.0
6 2015-10-28 2 0.0
7 2015-10-28 3 0.0
8 2015-10-28 4 0.0
...
14 2015-10-29 0 3.23
15 2015-10-29 1 3.23
...
houralways starts at 0 and increases by 1; it may or may not reach 23. it dateincreases one day at a time, but the number of date entries may differ from date to date, for example. - 2015-10-27has 4 entries, and 2015-10-28- up to line 13. The element levelwill always have the same value for this date, but this value may or may not be displayed for another date.
What I'm trying to get is a dictionary of this form
{'2015-10-27': '3', ..., '2015-10-29': '4', ...}
, level, .. level 2,5, [2, 3]. , , - "" , 10 if ( 9.xx) , , , , , .
?