Skip to content

Commit b652499

Browse files
committed
update: plot style
1 parent c682eac commit b652499

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

demo.py

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import numpy as np
22
from sklearn import linear_model
3-
import matplotlib
43
import matplotlib.pyplot as plt
54

65
#read data
@@ -13,11 +12,7 @@
1312
body_reg.fit(x_values, y_values)
1413

1514
#visualize results
16-
17-
plt.scatter(x_values, y_values, color='black')
18-
plt.plot(x_values, body_reg.predict(x_values), color='blue', linewidth=3)
19-
20-
plt.xticks(())
21-
plt.yticks(())
15+
plt.scatter(x_values, y_values)
16+
plt.plot(x_values, body_reg.predict(x_values), color='green')
2217

2318
plt.show()

0 commit comments

Comments
 (0)