Logistic regression is not used for regression! Let me explain:
1/8
1/8
I know it sounds stupid, but it's a classification model.
Why the name then?
Let's see how logistic regression works, so we can understand 👇
2/8
Why the name then?
Let's see how logistic regression works, so we can understand 👇
2/8
Logistic regression predicts if a given input point belongs to a certain class.
Its output is between 0 and 1.
This is a typical classification model.
The name doesn't describe the outcome. It tells how the method works.
3/8
Its output is between 0 and 1.
This is a typical classification model.
The name doesn't describe the outcome. It tells how the method works.
3/8
Logistic regression is an extension of linear regression.
The underlying concepts are similar: to 'regress' the independent against the dependent variables.
But logistic regression goes beyond and it transforms the output to binary.
4/8
The underlying concepts are similar: to 'regress' the independent against the dependent variables.
But logistic regression goes beyond and it transforms the output to binary.
4/8
With fancy statistical words, we can say: logistic regression is a generalized linear model where the dependent variable is binomially distributed.
Imagine this:
We want to predict if someone will pass the next exam or not based on the hours they studied.
5/8
Imagine this:
We want to predict if someone will pass the next exam or not based on the hours they studied.
5/8
If someone studies more, the probability is higher to pass.
Logistic regression assigns weights to the study hours and calculates a value for each student.
This value then goes through a logistic function, which converts it into a probability.
6/8
Logistic regression assigns weights to the study hours and calculates a value for each student.
This value then goes through a logistic function, which converts it into a probability.
6/8
If the probability is closer to 1 the student will probably pass (based on the model).
If we visualize the model (like in the video below), the curved line will show the decision boundary. This helps to classify whether a student will pass or fail.
7/8
If we visualize the model (like in the video below), the curved line will show the decision boundary. This helps to classify whether a student will pass or fail.
7/8
Did you like this post?
Hit that follow button for me and pay back with your support.
It literally takes 1 second for you but makes me 10x happier.
Thanks 😉
8/8
Hit that follow button for me and pay back with your support.
It literally takes 1 second for you but makes me 10x happier.
Thanks 😉
8/8
If you haven't already, join our newsletter DSBoost.
We share:
• Interviews
• Podcast notes
• Learning resources
• Interesting collections of content
dsboost.dev
We share:
• Interviews
• Podcast notes
• Learning resources
• Interesting collections of content
dsboost.dev
Loading suggestions...