import matplotlib matplotlib.use('Agg') import matplotlib.pyplot as plt import csv x = [] y = [] i = 1 with open('averagewer.txt','r') as csvfile: plots = csv.reader(csvfile, delimiter=' ') for row in plots: y.append(float(row[0])) x.append(int(i)) i=i+1 plt.plot(x,y) plt.ylabel('WER (%)') plt.xlabel('Build number') plt.title('Plot of average WER') plt.legend() plt.savefig('plotwer.png')