Python – Linear Regression – YouTube video

There is something interesting about linear regression. I have just noticed, that I have actually quite some articles on it some years ago, but today I wanted to make a YouTube video as well. Well, what is the difference this time? I really hope I have become a bit better in explaining basic theory and plotting data.

A plot from the code below

If not, then no worries – the third article will probably come in another 4 years, if you follow the linear regression. Just some minimal code from the video here, if you need to impress someone:

What does the code do? It plots the picture above the code, based on 2 options to draw regression lines. The first one is with manually defined intersept and slope and the second one is with the fitted one from the sklearn library. Run the code below to see it:

The rest is present in the YouTube video, I hope you enjoy it 🙂

The GitHub code is here:

https://github.com/Vitosh/Python_personal/blob/master/YouTube/016_Python-Linear-Regression/Linear-Regression.ipynb

🙂