Advertisement
Guest User

Untitled

a guest
Oct 17th, 2019
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.30 KB | None | 0 0
  1. # Listing 1
  2. import numpy as np
  3. import matplotlib.pyplot as plt
  4. from sklearn import linear_model
  5. import sklearn.metrics as metrics
  6.  
  7. x=np.arange(1,51)
  8. y=np.zeros(50)
  9. y[25:50]=1
  10. plt.scatter(x.ravel(), y, color='black', zorder=10)
  11. plt.ylabel('y')
  12. plt.xlabel('X')
  13. plt.ylim(-.25, 1.25)
  14. plt.xlim(0, 51)
  15. plt.show()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement