Logistic regression is a classification algorithm used on a discrete set of classes. Logistic regression transforms its output using the logistic sigmoid function to return a probability value which can then be mapped to two or more discrete classes. Logistic regression is an extension of simple linear regression.
Where can we use Logistic Regression? An example to understand where it can be used is that it can help to predict whether a student has passed or failed. Logistic regression predictions are discrete (only specific values or categories are allowed).
Logistic regression is the statistical technique used to predict the relationship between predictors (our independent variables) and a predicted variable (the dependent variable) where the dependent variable is binary (e.g., student [pass vs. fail], response [yes vs. no], score [high vs. low], etc).
Basic assumptions that must be met for logistic regression include independence of errors, linearity, absence of multicollinearity, and lack of strongly influential outliers.
Types of logistic regression:
- Binary
- Multi
- Ordinal
Binary Logistic Regression : This regression is used when our Y variable takes on only two values. Such a variable is referred to a “binary” or “dichotomous.” “Dichotomous” basically means two categories such as yes/no, defective/non-defective, success/failure, and so on. It helps us to understand if a condition is True of False, a student has passed of failed and so on.
Multiple Logistic Regression : This regression is used when we have one nominal variable and two or more measurement variables, and we want to know how the measurement variables affect the nominal variable. We can use it to predict probabilities of the dependent nominal variable. The nominal variable is the dependent (Y) variable; and we are studying the effect that the independent (X) variables have on the probability of obtaining a particular value of the dependent variable. For example, we might want to know the effect that blood pressure, age, and weight have on the probability that a person will have a heart attack in the next year.
Ordinal logistic regression : This regression is used to predict an ordinal dependent variable given one or more independent variables.