| Multivariate linear regression | Multiple linear regression |
|---|---|
| Multiple dependent and independent variables | Single dependent and multiple independent variables |
Linear regression weight update equation:



Multiple-feature gradient descent

Normal equation
The normal equation is an alternative technique to gradient descent for linear regression. It provides a closed-form solution for the weights (w) and bias (b) without iterations.
computationally expensive when the number of features is large (> 10,000).
Normal equation uses analytical approach when solving linear regression problems
Whereas gradient descent is a numerical approach
Feature scaling techniques
- Relative maximum scaling
each feature divided by maximum value, so maximum value becomes 1

- Mean Normalization
features are centered around zero. Results in values between -1 and 1
after normalization, values of features will be scaled down and centered around zero - Z-score Normalization
uses mean and std both. Transforms data into standard normal distribution where mean is 0 and std is 1
useful when features have different variances

How to test if your model has converged?
- Use learning curve graph
- Use automatic convergence test
let epsilon be 10^-3
if J <= epsilon
declare convergence