Book Image

Mastering Python for Data Science

By : Samir Madhavan
Book Image

Mastering Python for Data Science

By: Samir Madhavan

Overview of this book

Table of Contents (19 chapters)
Mastering Python for Data Science
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
7
Estimating the Likelihood of Events
Index

Chapter 7. Estimating the Likelihood of Events

Logistic regression is a type of regression analysis that helps in estimating the likelihood of an event to occur based on some given parameters. It is used as a classification technique with a binary outcome. The probabilities describing the possible outcomes of a single trial are modeled, as a function of the explanatory (predictor) variables, using a logistic function.

You have been already introduced to Logisitc regression in Chapter 5, Uncovering Machine Learning. In this chapter, you'll learn to:

  • Build a logistic regression model with statsmodels

  • Build a logistic regression model with SciKit

  • Evaluate and test the model