SlideShare a Scribd company logo
3
Most read
16
Most read
17
Most read
Logistic Regression
What is Logistic Regression?
Logistic Regression is a type of classification model based on supervised learning.
In supervised learning, we train the model using data which is well labelled that
means the data is already tagged with correct answers. Here, the feature values
will be independent variables and the target value will be dependent variable.
What is Logistic Regression? continues...
Logistic Regression 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 using Maximum Likelihood of occurring of an event.
Problems that can be solved using Logistic Regression
● How likely a Netflix user will pay for a particular series?
● How likely India will win the Cricket World Cup?
● How likely a test score of a student will help him to get admitted to a
university?
● How likely a politician’s tweet is positive or negative?
Types of Logistic Regression
● Binary Logistic Regression: It is used when there are only 2 outcome
category.
● Multinomial Logistic Regression: It is used when there are more than 2
outcome category.
When should we use Logistic Regression?
● When there is no linear relationship between dependent variable and
independent variable.
● Logistic Regression is more robust to outliers than the Linear Regression.
(hint: Log function vs squared function)
Hyperparameter in Logistic Regression
Learning Rate: The rate at which the weights of the model is updated. (too small
value: optimization rate will be very small, too large value: model won’t converge
to best value)
Early stopping (max_iter): It is used so that the model does not overfit with the
training data. So, we stop the training as soon as we get the best TEST score.
To optimize the hyperparameters, we use a method called Grid Search to
find the best combination of hyperparameters value for the model.
How Logistic Regression works?
During training, the model involves mostly in following things:
Input: feature values
Output: predicted values
Sigmoid: apply sigmoid function on Output
Error: find error using Log-loss formula
Update: update weight and bias of the classification line
How Logistic Regression works?
During training, the model involves mostly in following things:
Input: feature values
Output: predicted values
Sigmoid: apply sigmoid function on Output
Error: find error using Log-loss formula
Update: update weight and bias of the classification line
How Logistic Regression works?
During training, the model involves mostly in following things:
Input: feature values
Output: predicted values
Sigmoid: apply sigmoid function on Output
Error: find error using Log-loss formula
Update: update weight and bias of the classification line
How Logistic Regression works?
During training, the model involves mostly in following things:
Input: feature values
Output: predicted values
Sigmoid: apply sigmoid function on Output
Error: find error using Log-loss formula
Update: update weight and bias of the classification line
How Logistic Regression works?
During training, the model involves mostly in following things:
Input: feature values
Output: predicted values
Sigmoid: apply sigmoid function on Output
Error: find error using Log-loss formula
Update: update weight and bias of the classification line
How Logistic Regression works?
During training, the model involves mostly in following things:
Input: feature values
Output: predicted values
Sigmoid: apply sigmoid function on Output
Error: find error using Log-loss formula
Update: update weight and bias of the classification line
How Logistic Regression works?
During training, the model involves mostly in following things:
Input: feature values
Output: predicted values
Sigmoid: apply sigmoid function on Output
Error: find error using Log-loss formula
Update: update weight and bias of the classification line
How Logistic Regression works?
During training, the model involves mostly in following things:
Input: feature values
Output: predicted values
Sigmoid: apply sigmoid function on Output
Error: find error using Log-loss formula
Update: update weight and bias of the classification line
Demo
https://github.com/rajatsharma369007/Gradient_Descent_Algorithm/blob/master/G
radientdescent.ipynb
Advantages
➢ It is widely used technique because it is very efficient, doesn’t require too
many computational resources, it’s highly interpretable, it doesn’t require input
features to be scaled,it doesn’t require any tuning, it’s easy to regularize and it
outputs well-calibrated predicted probabilities.
➢ It is incredibly easy and quick to implement and very efficient to train.
Because of these facts, Logistic Regression is a good baseline that we can
use to measure the performance of other more complex algorithms.
➢ It works better when we remove the attributes that are unrelated to the output
variable as well as the attributes that are very similar(correlated) to each
other.
Disadvantages
➢ Logistic Regression is not one of the most powerful algorithms and can be
easily outperformed by the more complex ones.
➢ Another disadvantage is its high reliance on a proper presentation of our data.
And this means that it is not a useful tool unless we have already identified all
the important independent variables.
➢ Since its outcome is discrete,Logistic Regression can only predict a
Categorical Outcome.
THANK YOU !

More Related Content

PDF
Logistic Regression in Python | Logistic Regression Example | Machine Learnin...
PPTX
Machine Learning
PDF
Deep learning - A Visual Introduction
PPTX
Social-media-PPT.pptx
PDF
Research gate
PPTX
Exploratory Research Design
PPTX
PARKINSON DISEASE
PDF
Rapport de stage: mastère ISIC (Business Intelligence)
Logistic Regression in Python | Logistic Regression Example | Machine Learnin...
Machine Learning
Deep learning - A Visual Introduction
Social-media-PPT.pptx
Research gate
Exploratory Research Design
PARKINSON DISEASE
Rapport de stage: mastère ISIC (Business Intelligence)

What's hot (20)

PPTX
Logistic Regression | Logistic Regression In Python | Machine Learning Algori...
PDF
Logistic regression in Machine Learning
ODP
Machine Learning With Logistic Regression
PPTX
K Nearest Neighbor Algorithm
PPTX
Linear Regression Analysis | Linear Regression in Python | Machine Learning A...
PPTX
Logistic regression
PPTX
Supervised and Unsupervised Learning In Machine Learning | Machine Learning T...
PPTX
Random forest algorithm
PPTX
Linear Regression and Logistic Regression in ML
PPTX
Machine Learning Tutorial Part - 2 | Machine Learning Tutorial For Beginners ...
PPTX
Gradient descent method
ODP
Introduction to Bayesian Statistics
PPTX
Lecture 18: Gaussian Mixture Models and Expectation Maximization
PPTX
Hyperparameter Tuning
PPTX
An overview of gradient descent optimization algorithms
PDF
Logistic regression
PPTX
KNN Algorithm - How KNN Algorithm Works With Example | Data Science For Begin...
PPTX
Presentation on unsupervised learning
PDF
Linear models for classification
Logistic Regression | Logistic Regression In Python | Machine Learning Algori...
Logistic regression in Machine Learning
Machine Learning With Logistic Regression
K Nearest Neighbor Algorithm
Linear Regression Analysis | Linear Regression in Python | Machine Learning A...
Logistic regression
Supervised and Unsupervised Learning In Machine Learning | Machine Learning T...
Random forest algorithm
Linear Regression and Logistic Regression in ML
Machine Learning Tutorial Part - 2 | Machine Learning Tutorial For Beginners ...
Gradient descent method
Introduction to Bayesian Statistics
Lecture 18: Gaussian Mixture Models and Expectation Maximization
Hyperparameter Tuning
An overview of gradient descent optimization algorithms
Logistic regression
KNN Algorithm - How KNN Algorithm Works With Example | Data Science For Begin...
Presentation on unsupervised learning
Linear models for classification
Ad

Similar to Logistic regression : Use Case | Background | Advantages | Disadvantages (20)

PPTX
24AI201_AI_Unit_4 (1).pptx Artificial intelligence
PPTX
PPTX
Copy of CRICKET MATCH WIN PREDICTOR USING LOGISTIC ...
PPTX
Bagging.pptx
PPTX
INTERNSHIP presentation on machiine learning
PPTX
ML Study Jams - Session 3.pptx
PPTX
Digital Marketing Campaign Conversion Prediction
PPTX
Digital Marketing Campaign Conversion Prediction.
PDF
Training Deep Networks with Backprop (D1L4 Insight@DCU Machine Learning Works...
PDF
AI-Assisted Feature Selection for Big Data Modeling
PDF
Methods of Optimization in Machine Learning
PPTX
Machine learning Algorithms with a Sagemaker demo
PDF
Demystifying Xgboost
PPTX
Understanding GBM and XGBoost in Scikit-Learn
PDF
Barga Data Science lecture 10
PPTX
Machine Learning in the Financial Industry
PPTX
Aspiring Minds | Automata
PPTX
Lecture 3.1_ Logistic Regression.pptx
PPTX
Building Continuous Learning Systems
PPTX
Classification Algortyhm of Machine Learning
24AI201_AI_Unit_4 (1).pptx Artificial intelligence
Copy of CRICKET MATCH WIN PREDICTOR USING LOGISTIC ...
Bagging.pptx
INTERNSHIP presentation on machiine learning
ML Study Jams - Session 3.pptx
Digital Marketing Campaign Conversion Prediction
Digital Marketing Campaign Conversion Prediction.
Training Deep Networks with Backprop (D1L4 Insight@DCU Machine Learning Works...
AI-Assisted Feature Selection for Big Data Modeling
Methods of Optimization in Machine Learning
Machine learning Algorithms with a Sagemaker demo
Demystifying Xgboost
Understanding GBM and XGBoost in Scikit-Learn
Barga Data Science lecture 10
Machine Learning in the Financial Industry
Aspiring Minds | Automata
Lecture 3.1_ Logistic Regression.pptx
Building Continuous Learning Systems
Classification Algortyhm of Machine Learning
Ad

Recently uploaded (20)

DOCX
The AUB Centre for AI in Media Proposal.docx
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
Encapsulation_ Review paper, used for researhc scholars
PPT
Teaching material agriculture food technology
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Approach and Philosophy of On baking technology
PDF
Encapsulation theory and applications.pdf
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
KodekX | Application Modernization Development
PDF
Spectral efficient network and resource selection model in 5G networks
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PDF
cuic standard and advanced reporting.pdf
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PPTX
Big Data Technologies - Introduction.pptx
PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
The AUB Centre for AI in Media Proposal.docx
Understanding_Digital_Forensics_Presentation.pptx
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Digital-Transformation-Roadmap-for-Companies.pptx
Encapsulation_ Review paper, used for researhc scholars
Teaching material agriculture food technology
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Approach and Philosophy of On baking technology
Encapsulation theory and applications.pdf
The Rise and Fall of 3GPP – Time for a Sabbatical?
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Programs and apps: productivity, graphics, security and other tools
KodekX | Application Modernization Development
Spectral efficient network and resource selection model in 5G networks
Chapter 3 Spatial Domain Image Processing.pdf
cuic standard and advanced reporting.pdf
Advanced methodologies resolving dimensionality complications for autism neur...
Big Data Technologies - Introduction.pptx
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton

Logistic regression : Use Case | Background | Advantages | Disadvantages

  • 2. What is Logistic Regression? Logistic Regression is a type of classification model based on supervised learning. In supervised learning, we train the model using data which is well labelled that means the data is already tagged with correct answers. Here, the feature values will be independent variables and the target value will be dependent variable.
  • 3. What is Logistic Regression? continues... Logistic Regression 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 using Maximum Likelihood of occurring of an event.
  • 4. Problems that can be solved using Logistic Regression ● How likely a Netflix user will pay for a particular series? ● How likely India will win the Cricket World Cup? ● How likely a test score of a student will help him to get admitted to a university? ● How likely a politician’s tweet is positive or negative?
  • 5. Types of Logistic Regression ● Binary Logistic Regression: It is used when there are only 2 outcome category. ● Multinomial Logistic Regression: It is used when there are more than 2 outcome category.
  • 6. When should we use Logistic Regression? ● When there is no linear relationship between dependent variable and independent variable. ● Logistic Regression is more robust to outliers than the Linear Regression. (hint: Log function vs squared function)
  • 7. Hyperparameter in Logistic Regression Learning Rate: The rate at which the weights of the model is updated. (too small value: optimization rate will be very small, too large value: model won’t converge to best value) Early stopping (max_iter): It is used so that the model does not overfit with the training data. So, we stop the training as soon as we get the best TEST score. To optimize the hyperparameters, we use a method called Grid Search to find the best combination of hyperparameters value for the model.
  • 8. How Logistic Regression works? During training, the model involves mostly in following things: Input: feature values Output: predicted values Sigmoid: apply sigmoid function on Output Error: find error using Log-loss formula Update: update weight and bias of the classification line
  • 9. How Logistic Regression works? During training, the model involves mostly in following things: Input: feature values Output: predicted values Sigmoid: apply sigmoid function on Output Error: find error using Log-loss formula Update: update weight and bias of the classification line
  • 10. How Logistic Regression works? During training, the model involves mostly in following things: Input: feature values Output: predicted values Sigmoid: apply sigmoid function on Output Error: find error using Log-loss formula Update: update weight and bias of the classification line
  • 11. How Logistic Regression works? During training, the model involves mostly in following things: Input: feature values Output: predicted values Sigmoid: apply sigmoid function on Output Error: find error using Log-loss formula Update: update weight and bias of the classification line
  • 12. How Logistic Regression works? During training, the model involves mostly in following things: Input: feature values Output: predicted values Sigmoid: apply sigmoid function on Output Error: find error using Log-loss formula Update: update weight and bias of the classification line
  • 13. How Logistic Regression works? During training, the model involves mostly in following things: Input: feature values Output: predicted values Sigmoid: apply sigmoid function on Output Error: find error using Log-loss formula Update: update weight and bias of the classification line
  • 14. How Logistic Regression works? During training, the model involves mostly in following things: Input: feature values Output: predicted values Sigmoid: apply sigmoid function on Output Error: find error using Log-loss formula Update: update weight and bias of the classification line
  • 15. How Logistic Regression works? During training, the model involves mostly in following things: Input: feature values Output: predicted values Sigmoid: apply sigmoid function on Output Error: find error using Log-loss formula Update: update weight and bias of the classification line
  • 17. Advantages ➢ It is widely used technique because it is very efficient, doesn’t require too many computational resources, it’s highly interpretable, it doesn’t require input features to be scaled,it doesn’t require any tuning, it’s easy to regularize and it outputs well-calibrated predicted probabilities. ➢ It is incredibly easy and quick to implement and very efficient to train. Because of these facts, Logistic Regression is a good baseline that we can use to measure the performance of other more complex algorithms. ➢ It works better when we remove the attributes that are unrelated to the output variable as well as the attributes that are very similar(correlated) to each other.
  • 18. Disadvantages ➢ Logistic Regression is not one of the most powerful algorithms and can be easily outperformed by the more complex ones. ➢ Another disadvantage is its high reliance on a proper presentation of our data. And this means that it is not a useful tool unless we have already identified all the important independent variables. ➢ Since its outcome is discrete,Logistic Regression can only predict a Categorical Outcome.