Created
August 21, 2017 00:19
-
-
Save b0noI/1f1b591505572086d7d5c06212033778 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# lineral equation | |
def f2(x): | |
# a = 5 | |
# b = 2 | |
return - 5 * x + 2 | |
# Data | |
X2 = np.arange(100, step=0.001) | |
Y2 = f2(X2) | |
# Split data for taining and evaluation | |
X2_train, X2_test, Y2_train, Y2_test = train_test_split(X2, Y2) | |
figure = plt.figure() | |
plt.plot(X2_train, Y2_train, 'r') | |
plt.xlabel('x') | |
plt.ylabel('y') | |
plt.title('simple line') | |
plt.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment