22 lines
411 B
Python
22 lines
411 B
Python
import matplotlib.pyplot as plt
|
|
import matplotlib.cbook as cbook
|
|
|
|
import numpy as np
|
|
import pandas as pd
|
|
|
|
f = open('time.csv', 'r')
|
|
y = []
|
|
for l in f.readlines():
|
|
y.append(float(l))
|
|
|
|
x = range(0, len(y))
|
|
plt.plot(x, y, label = 'time (s)')
|
|
|
|
plt.title('Time to run with k queens')
|
|
plt.xlabel('k')
|
|
plt.ylabel('time (s)')
|
|
plt.rcParams['axes.autolimit_mode'] = 'round_numbers'
|
|
plt.grid()
|
|
plt.legend()
|
|
plt.show()
|