In [27]:
import csv
import matplotlib.pyplot as plt

fig = plt.figure(1)

for idx, c in enumerate((1, 10, 100, 500, 1000)):
    plt.subplot(5, 1, idx+1)
    plt.title('conc={0}'.format(c))
    for color, server in zip(['blue', 'green'], ['optimized', 'baseline']):
        with open('{0}_n10000_c{1}_result.csv'.format(server, c)) as csvfile:
            reader = csv.reader(csvfile)
            header = reader.next()
            percents = []
            times = []
            for percent, time in reader:
                percents.append(int(percent))
                times.append(float(time))
            plt.plot(percents, times, label=server + '/' + str(c), color=color)

plt.show()
plt.close()

In [26]:


In [ ]: