Machine learning univariate linear regression
model representation model representation
introduction
Given data housing area and house prices, then housing area as the abscissa, ordinate housing price, the plotted data points. By drawing curves, get the model house prices, housing prices is obtained based on floor area, which is a Regression Problem (regression).
definition
Regression is based on an accurate means of data before output value predicted, i.e., predict real_valued output.
Training set notation:
m = Number The of Training examples there are m groups housing area and price data
x's = "input" variable / features House size
y's = "output" variable / features house price
(x, y) = one training example a training sample
training
The learning algorithm is fed the data set, Learning Algorithm, the output function H , H is a mapping from x to y.
Housing area based on the input x, by function h calculated the housing prices y.
Said following equation
H (X) = [theta] 0 + [theta] . 1 X
is a
Linear regression with one variable or Univariate linear regression (univariate linear regression)
Cost Function The cost function
[theta] I : model parameters, i.e., a linear function
Parameters:
Cost Function The cost function:
I.e. squared error loss function square error function.
Goal target: