/linear-regression-artificial-data

Create 20 linearly correlated artificial data then visualize it and calculate the coefficient and the intercept values also evaluate the RMSE.

Primary LanguageJupyter Notebook

Linear Regression for Artificial Data

-- Project Status: Completed

Project Objective

Create 20 linearly correlated artificial data then visualize it and calculate the coefficient and the intercept values also evaluate the RMSE.

Methods Used

  • Linear Regression

Language

  • Python

Module

  • Numpy
  • Matplotlib
  • Pandas
  • Sympy
  • Scikit-learn

Step-by-step

  1. Create 20 random data with random
  2. For manual, calculate with the formula for coefficient and intercept
  3. For Scikit-Learn modules, use linear_model
  4. Calculate the RMSE

Obtained for the manual model

  • Coefficient = 4.989500838411049
  • Intercepts = -4.400486397583558
  • RMSE = 0.2810131078597593

Obtained for Scikit-Learn models

  • Coefficient = 4.98950084
  • Intercepts = -4.400486397583559
  • RMSE = 0.28101310785975925

Getting Started

  1. All of the scripts are being kept here.