Introduction to Logistic regression
While we continued to write the numpy code for linear regression we were introduced to Logistic Regression. It is
a statistical method for analyzing a dataset in which there are one or
more independent variables that determine an outcome. The outcome is
measured with a dichotomous variable (in which there are only two
possible outcomes). It is used to predict a binary outcome (1 / 0, Yes /
No, True / False) given a set of independent variables. To represent
the binary/categorical outcome, we use dummy variables. You can also
think of logistic regression as a special case of linear regression when
the outcome variable is categorical, where we are using log of odds as
the dependent variable. In simple words, it predicts the probability of
occurrence of an event by fitting data to a logit function.
S(z)=11+e−z
It required us to understand sigmoid function. In order to map predicted values to probabilities, we use the sigmoid function.
The function maps any real value into another value between 0 and 1. In
machine learning, we use sigmoid to map predictions to probabilities.
Comments
Post a Comment