機器學習筆記(3)-----梯度下降算法中特徵縮放

多變量線性迴歸     計算代價函數 ,其中: octave求代價函數J(theta)代碼:        function J = costFunctionJ(X,y,theta)        m = size(X,1);           prediction = X*theta;        sqrErrors = (prediction-y).^2;        J  = 1/(2
相關文章
相關標籤/搜索