Chapter 5
Logistic Regression
Logistic regression is a foundational algorithm for classification tasks, where the goal is to predict the class or category of a given input, such as determining whether an email is spam or not, or predicting whether a patient has a certain disease based on clinical features. Because of its simplicity, interpretability, and effectiveness, it is widely used as a baseline model against which more complex classifiers are compared.
Originally developed for binary classification, logistic regression models the probability that an input belongs to the “positive” class rather than the “negative” class by applying the logistic (sigmoid) function to a linear combination of the input features. This function maps real-valued ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access