Machine Learning Notes ——Linear Regression
2014-03-12 22:49
309 查看
Linear Regression with One Variable
Cost function
Gradient descent
Linear Regression with multiple variables
Gradient descent for multiple variables
Feature Scaling
Xi = ( Xi - Avg) / (Max - Min)
Learning rate
If a is too small: slow convergence.
If a is too large: J(θ) may
not decrease on every iteration; may not converge.
Normal equation
X *θ= Y
XTX*θ= XTY
(XTX)-1(XTX)*θ= (XTX)-1XTY
θ=
(XTX)-1XTY
Normal
equation and non-invertibility
•Redundant features (linearly dependent).
E.g. X1 = size in feet2
X2 = size in m2
•Too many features (e.g. m<=n ).
Delete some features, or use regularization.
Cost function
Gradient descent
Linear Regression with multiple variables
Gradient descent for multiple variables
Feature Scaling
Xi = ( Xi - Avg) / (Max - Min)
Learning rate
If a is too small: slow convergence.
If a is too large: J(θ) may
not decrease on every iteration; may not converge.
Normal equation
X *θ= Y
XTX*θ= XTY
(XTX)-1(XTX)*θ= (XTX)-1XTY
θ=
(XTX)-1XTY
Normal
equation and non-invertibility
•Redundant features (linearly dependent).
E.g. X1 = size in feet2
X2 = size in m2
•Too many features (e.g. m<=n ).
Delete some features, or use regularization.
相关文章推荐
- machine learning advanced lecture notes
- Machine Learning Notes
- [机器学习基础] Notes on Machine Learning
- Machine Learning Notes III
- Notes about <Oblivious Multi-Party Machine Learning on Trusted Processors>
- Machine Learning Algorithms Study Notes(1)--Introduction
- Machine Learning Notes - PLA
- Machine Learning Algorithms Study Notes
- 【Machine Learning notes(机器学习笔记-001)】
- Machine Learning Notes
- Machine Learning Algorithms Study Notes--Supervised Learning
- Machine Learning Algorithms Study Notes(4)—无监督学习(unsupervised learning)
- Machine Learning Algorithms Study Notes(5)—Reinforcement Learning
- Notes - Coursera MachineLearning by Andrew NG - Week1
- Machine Learning Lecture Notes
- Machine Learning Notes I: The Standard Linear Model
- Machine Learning Algorithms Study Notes(3)--Learning Theory
- Machine Learning Lecture Notes
- machine learning advanced lecture notes
- Machine Learning Lecture Notes