回归方程(regression equation)
octave 代码示意
h = X * theta
代价函数(Cost Function)
最小均方(LMS,Least Mean Square)
J = 0.5 * m^-1 * (X*theta-y)' * (X*theta-y);
梯度降落(Gradient Descent)
theta = theta - alpha * m ^ -1 * X' * (X * theta - y)
随机梯度降落(Random Gradient Descent)
正规方程(Normal Equation)
theta=pinv(X'*X)*X'*y