Skip to content
This repository has been archived by the owner on Sep 23, 2020. It is now read-only.

Commit

Permalink
or maybe it was this
Browse files Browse the repository at this point in the history
  • Loading branch information
buzztroll committed Oct 8, 2012
1 parent d39b861 commit 5a8e1b0
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions nimstat/graph.py
Expand Up @@ -187,8 +187,9 @@ def make_stack_bar_percent(data, labels, filename, uptime, maxdenom, title=None,
print data
print uptime
for i in range(0, len(uptime)):
if uptime[i] < data[i]:
uptime[i] = data[i]
d = data[i]
if uptime[i] < d[1]:
uptime[i] = d[1]
print 'warning santizing data at %d' % (i)
pdata = []
for i in range(0, len(data)):
Expand All @@ -202,7 +203,7 @@ def make_stack_bar_percent(data, labels, filename, uptime, maxdenom, title=None,
updata = []
for i in range(0, len(maxdenom)):
d = uptime[i]
numer = d[1]
numer = d
updata.append(100.0 - ((numer/float(maxdenom[i])) * 100.0))

cla()
Expand Down

0 comments on commit 5a8e1b0

Please sign in to comment.