9 frames
/usr/local/lib/python3.8/dist-packages/matplotlib/category.py in update(self, data)
208 # check if convertible to number:
209 convertible = True
--> 210 for val in OrderedDict.fromkeys(data):
211 # OrderedDict just iterates over unique values in data.
212 cbook._check_isinstance((str, bytes), value=val)
Replacing Salary dataframe by currency dataframe, it returns the folllwing error
TypeError Traceback (most recent call last) in
2
3 plt.figure()
----> 4 plt.scatter(X_train, y_train, color='blue', label="True Value")
5 plt.plot(X_train, y_train_pred, color='black', linewidth=2, label="Prediction")
6 plt.xlabel("Years of Experiences")
9 frames /usr/local/lib/python3.8/dist-packages/matplotlib/category.py in update(self, data) 208 # check if convertible to number: 209 convertible = True --> 210 for val in OrderedDict.fromkeys(data): 211 # OrderedDict just iterates over unique values in data. 212 cbook._check_isinstance((str, bytes), value=val)
TypeError: unhashable type: 'numpy.ndarray'