Operand Error creating a Graph using reportlab
<p>I'm new to python and i have been tasked to make a vertical bar chart from a text document, i have put the x axis information into a list and the data into a list as well. The problem i am having is when trying to output the chart I get an error saying : TypeError: unsupported operand type(s) for -: 'str' and 'int'. And I am struggling to figure out how to solve that error.
Do I need to type-cast one of the lists? Or are the lists the wrong way to do it?</p>

<p>Here's my code:</p>

<pre><code>from reportlab.graphics.shapes import Drawing
from reportlab.graphics.charts.barcharts import VerticalBarChart

ExifOutput = open('ExifOutput.txt', 'r')

ImageMakeContainer = []
Container = []
makeList = []
numberList = []

lineReader = ExifOutput.readlines()

for line in lineReader:
    if 'Image Make: ' in line:
        ImageMakeContainer.append(line[13:-2])

for item in set(ImageMakeContainer):
    Container.append(item + " " + str(ImageMakeContainer.count(item)))

print Container

for data in Container:

    [int(num) for num in data.split() if num.isdigit()]

    make = data[0:-(len(num) + 1)]

    makeList.append(make)
    numberList.append(num)

print numberList
print makeList

ExifOutput.close()

data = numberList
axis = makeList

graph = Drawing(400, 300)

chart = VerticalBarChart()
chart.width = 300
chart.height = 200
chart.x = 30
chart.y = 40
chart.data = data
chart.categoryAxis.categoryNames = axis
chart.valueAxis.valueMin = 0

graph.add(chart)
graph.save(fnRoot='TestGraph', formats=['png', 'pdf'])
</code></pre>

<p>Hope I was clear enough for you. (The print statements are just there to check the contents of the lists)</p>

<p><strong>[EDIT]</strong> The output of the prints are as follows:</p>

<pre><code>['Apple 1', 'FUJIFILM 5', 'Samsung Techwin 1']
['1', '5', '1']
['Apple', 'FUJIFILM', 'Samsung Techwin']
</code></pre>
