Logistic Regression
In our last article we got some insight about linear regression which predicts a continuous value as output based on the independent variables (inputs) forming a linear line to represent existing data points and predict new data point based on that equation. Here’s a link if you want to go through it
https://saichandra1199.medium.com/linear-regression-1e279814e2bb
Now lets see about Logistic Regression, If we need to get a logical output like True or False , 1 or 0 instead of a continuous value we use this type of regression. It takes probability of all the outputs and considers most probable one as the original output. Where we can use threshold to make decisions.
For example, If we are classifying spam or not spam cases where spam values are mostly less than 0.5 and not spam probability values are mostly above 0.5 then we can fix our threshold as 0.5 where the model can differentiate well between two classes.

FYI , Some of the spam cases may get high probability and not spam may get low probability. Any model will not reach to 100% accuracy. Here it forms a S- curve based on the threshold value, It is not fixed threshold may vary based on the situations and fix with the one which classifies with good accuracy. Even if the input parameters are more this helps to finalize them to get a single probability value between 0 and 1 to predict its class. This probability is obtained after many Activations and Normalizations applied on the data. We will go through those topics in a brief manner in our coming articles.
Thank You!! for reading…