arrange values and labels on plots xticks
plt.plot(neighbors, train_scores, label=”Train Score”) plt.plot(neighbors, test_scores, label=”Test Score”) plt.xticks(np.arange(1,21,1)) plt.xlabel(“Number of Neighbors”) plt.ylabel(“Score”) plt.legend() plt.show() `print(f”Maximum KNN score on the test data is: {max(test_scores)*100:.2f}%”)` it gives me a Type error TypeError Traceback (most recent call last) Cell In[62], line 5 3 plt.plot(neighbors, train_scores, label=”Train Score”) 4 plt.plot(neighbors, test_scores, label=”Test Score”) —-> 5 plt.xticks(np.arange(1,21,1)) 6 plt.xlabel(“Number […]