-
-
Save adarsh1021/b33108e9a6c899583afabf169b6bae6d 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
# Making the imports | |
import numpy as np | |
import pandas as pd | |
import matplotlib.pyplot as plt | |
plt.rcParams['figure.figsize'] = (12.0, 9.0) | |
# Preprocessing Input data | |
data = pd.read_csv('data.csv') | |
X = data.iloc[:, 0] | |
Y = data.iloc[:, 1] | |
plt.scatter(X, Y) | |
plt.show() |
@Rajeswaritce , Hi mam, you can use the below code for create the linear data.
import numpy as np
x = np.linspace(0, 100, 100) # 1000 values between 0 and 100
delta = np.random.uniform(-10, 10, x.size)
y = 0.4*x + 3 + delta
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
How to have access to data file?