Working steps for creating a Machine Learning program:
The first step is to get the data:
All the data for machine learning posts can be found here: https://github.com/geekRishabhjain/MLDataFolder
The data for Linear Regression in one variable is in the file ex1data1.txt.
Second is to feed the data into a learning algorithm. The learning algorithm learns parameters that will be used to create a hypothesis (usually denoted using h). When a new set of data is fed into h, this h will predict the estimate.
Representing the h:
The h can of several types, depending on the algorithm. Here as we are learning Linear Regression, h will be represented using a straight line.
h for Linear Regression:
We represent h with two parameters theta0 and theta1.
Thus the algorithm will learn theta0 and theta1. Using these we create a straight line,
h = theta0 + theta1*X.
Thus, whenever we have to estimate for any size X, we put it into the above function, which produces the predicted price.
No comments:
Post a Comment