Data Science, Regression, Machine Learning, Polynomial Regression, Towards Data Science.
Regression. Let’s generate some data which is nonlinear. m = 100 X = 6 * np.random.rand(m, 1) - 3 y = 0.5 * X**2 + X + 2 + np.random.randn(m, 1) # plotting data plt.plot(X,y,'b.') Generated data Using sklearn we can easily generate data with help of PolynomialFeatures() Let’s implement it. from