Giter VIP home page Giter VIP logo

linear-regression's Introduction

Linear-regression

Summary: In this project, you will implement your first machine learning algorithm

The aim of this project is to introduce you to the basic concept behind machine learning. For this project, you will have to create a program that predicts the price of a car by using a linear function train with a gradient descent algorithm. We will work on a precise example for the project, but once you’re done you will be able to use the algorithm with any other dataset.

In this project you are free to use whatever language you want. You are also free to use any libraries you want as long as they do not do all the work for you. For example, the use of python’s numpy.polyfit is considered cheating.

  • You should use a language that allows you to easily visualize your data : it will be very helpful for debugging.

The first program will be used to predict the price of a car for a given mileage. When you launch the program, it should prompt you for a mileage, and then give you back the estimated price for that mileage. The program will use the following hypothesis to predict the price :

Ekran görüntüsü 2023-08-04 010827

The second program will be used to train your model. It will read your dataset file and perform a linear regression on the data. Once the linear regression has completed, you will save the variables theta0 and theta1 for use in the first program. You will be using the following formulas :

Ekran görüntüsü 2023-08-04 011218

I let you guess what m is :) Note that the estimatePrice is the same as in our first program, but here it uses your temporary, lastly computed theta0 and theta1. Also, don’t forget to simultaneously update theta0 and theta1.

  • Plotting the data into a graph to see their repartition.
  • Plotting the line resulting from your linear regression into the same graph, to see the result of your hard work !
  • A program that calculates the precision of your algorithm.
LinearRegression.mp4

linear-regression's People

Contributors

denizkarhan avatar

Watchers

Kostas Georgiou avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.