GradDescent icon indicating copy to clipboard operation
GradDescent copied to clipboard

MATLAB implementation of Gradient Descent algorithm for Multivariate Linear Regression

GradDescent

MATLAB implementation of Gradient Descent algorithm for Multivariable Linear Regression. This code example includes,

  • Feature scaling option
  • Choice of algorithm termination based on either gradient norm tolerance or fixed number of iterations
  • Randomized feature vector with randomized exponents (the exact functional relationship is not linear but with random powers of feature vectors)
  • Choice of number of observations and features
  • Choice of 'learning rate' and number of iterations
  • Final table of actual functional coefficients and linear regression coefficients side by side