An extremely easy to understand python implementation of Lin Reg , using cost minimaztion and gradient-descent rather than auto-fitting libraries.
The linear regression task is achieved by first loading the dataset and normalizing it.
The next step is to define a cost function which will determine how perfectly our estimated parameters fit the dataset.
The next step is to minimize this cost function, using one of the simplest algorithms i.e gradient descent, which moves the parameter estimates in the direction of the steepest slope so as to converge to a global/local minimum, which in turn gives the best possible line to fit the given dataset.