0
我正在嘗試繪製連接的折線圖。如果我對下面的代碼進行更改,則無法顯示該圖。在matplotlib中繪製折線圖
我的情節,截至目前,充滿了無關的點。
如何生成連接點的線圖?
x = np.zeros(sheet_1.max_row)
y = np.zeros(sheet_1.max_row)
print (sheet_1.max_row)
print (sheet_1.max_column)
f = open("Bad_Data_Points_CD25.txt", "w")
for i in range(0, 10): #change to 1000
for j in range(0, 289): # change to 289
x[i] = sheet_1.cell(row=i + 1, column=j + 1).value #J + 1 changed to J
print x[i]
plt.plot(i, x[i],'go-', label='Values')
plt.grid(True)
plt.title("ABCD")
plt.ylabel("ABCD")
plt.ylim(0,0.15)
plt.xlabel("ABCD")
plt.xlim(0, 10)
plt.show()