In [1]:
import pandas as pd

In [2]:
%matplotlib inline

In [4]:
overall_drain = pd.Series([1.31,1.89,1.81,1.87,0.74,0.91,0.62,1.11,1.0])

In [5]:
overall_drain


Out[5]:
0    1.31
1    1.89
2    1.81
3    1.87
4    0.74
5    0.91
6    0.62
7    1.11
8    1.00
dtype: float64

In [6]:
overall_drain.describe()


Out[6]:
count    9.000000
mean     1.251111
std      0.495718
min      0.620000
25%      0.910000
50%      1.110000
75%      1.810000
max      1.890000
dtype: float64

In [9]:
overall_drain.plot(kind="bar", title = "Screen Off Discharge Rate (%/hr)")


Out[9]:
<matplotlib.axes.AxesSubplot at 0x109a82190>

In [13]:
cfc_drain = pd.DataFrame([{'drain': 4.07, 'hours': 6.0},
 {'drain': 1.86, 'hours': 5.0},
 {'drain': 3.44, 'hours': 6.0},
 {'drain': 8.14, 'hours': 13.0},
 {'drain': 4.36, 'hours': 7.0},
 {'drain': 8.03, 'hours': 13.0},
 {'drain': 11.03, 'hours': 19.0},
 {'drain': 4.67, 'hours': 8.0},
 {'drain': 3.52, 'hours': 5.0}])

In [14]:
cfc_drain.hourly = cfc_drain.drain/cfc_drain.hours

In [18]:
cfc_drain.hourly


Out[18]:
0    0.678333
1    0.372000
2    0.573333
3    0.626154
4    0.622857
5    0.617692
6    0.580526
7    0.583750
8    0.704000
dtype: float64

In [19]:
cfc_drain.hourly.plot(kind="bar", title = "cfctracker discharge rate (%/hr)")


Out[19]:
<matplotlib.axes.AxesSubplot at 0x109c794d0>

In [ ]: