How Logistic Regression works | AI ML tutorials by a Data Scientist | Thinking Neuron
Logistic regression is based on logit function logit(x) = log(x / (1 – x))
The output is a value between 0 to 1. It is the probability of an event’s occurrence.
E.g. There is an 80% chance that the loan application is good, approve it.
The coefficients β0, β1, β2, β3… are found using Maximum Likelihood Estimation Technique. Basically, if the Target Variable’s value (y) is 1, then the probability of one “P(1)” should be as close to 1 as possible and the probability of zero “P(0)” should be as close to 0 as possible. Find those coefficients which satisfy both the conditions.
The Goodness of Fit (AIC and Deviance ):
These measures help to understand how good the model fits the data. Please note This is NOT the Accuracy of the model.
AIC The Akaike Information Criterion (AIC)
provides a method for assessing the quality
of your model through comparison of
related models. The number itself is not
meaningful. If you have more than one
model then you
should select the model that has the
smallest AIC.
The null deviance shows how well the
Target variable is predicted by a model that
includes only the intercept (grand mean).
The Residual deviance shows how well the target variable is predicted by a model that includes multiple independent predictors
Accuracy Measurement is done using f1-Score/Precision/Recall/ROC/AUC.
Learn more about Logistic Regression at the Thinking Neuron Website using the link below:
https://thinkingneuron.com/data-science-interview-questions-for-it-industry-part-3-supervised-ml/#Explain-how-Logistic-Regression-algorithm-works
#logisticregression #datascience #datascienceinterview #datascienceinterviewquestions #machinelearning #supervisedlearning