Logistic regression is a machine learning model that predicts the probability of a yes-or-no outcome, such as whether a customer will buy, churn or default, from a set of input factors. It is one of the oldest and most widely used models in business because it is fast, needs modest data and shows how much each factor matters. Saraswati Stitch often uses it as the baseline before trying anything more complex.
How it works
IBM describes logistic regression as a supervised machine learning algorithm used for classification. The model weighs each input, adds them up and passes the total through an S-shaped curve that squeezes any number into a value between 0 and 1. That value is the probability; a threshold, often 0.5, turns it into a yes or no.
Because each input has its own weight, you can read the result: for example, that customers on monthly contracts are far more likely to cancel than those on annual ones, with everything else held equal.
Business examples
| Question | Inputs |
|---|---|
| Will this lead convert? | Source, company size, pages viewed, email opens |
| Will this customer churn? | Contract type, usage trend, support tickets |
| Is this transaction fraud? | Amount, location, device, time |
| Will this invoice be paid late? | Customer history, invoice size, terms |
| Is this email spam? | Words, links, sender reputation |
Linear vs logistic regression
Linear regression predicts a number, such as next month's sales. Logistic regression predicts the probability of a category, such as buy or not buy. The names are similar because both weigh inputs, but they answer different questions.
What does a logistic regression tell you?
The probability of the outcome for each case, and which factors push that probability up or down and by how much. That makes it useful for decisions that must be explained, such as credit, and for ranking leads or accounts by risk.
To judge a model like this, look at its confusion matrix and precision and recall. For a model that captures more complex patterns, compare it with a decision tree.
Saraswati Stitch®