1 Logistic Regression

0.0(0)
studied byStudied by 0 people
GameKnowt Play
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/17

flashcard set

Earn XP

Description and Tags

This is binary classification

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

18 Terms

1
New cards

Logistic regression is a

Logistic regression predicts binary outcomes by modelling the probability using a

logistic function. (Classification mode)

<p>Logistic regression predicts binary outcomes by modelling the probability using a</p><p>logistic function. (Classification mode)</p>
2
New cards

Example of logistic regression

Spam or not spam

3
New cards

What is a Confusion Matrix in Multiclass Classification?

A confusion matrix for multiclass classification is a table that allows the visualization of the performance of a classification model by comparing predicted labels with actual labels across all classes.

For a multiclass problem with N classes, the matrix is an table where: Rows represent the true classes (actual labels). Columns represent the predicted classes (model's output). From this matrix, various metrics like accuracy, precision, recall, and F1 score can be calculated for each class individually

4
New cards

Sqaush line

Making the line limit the value beteween 0 & 1.

5
New cards

Logit Model

if op is between 0 & 1 (Logistic regrssion) then we call logit model. this happen when we attach sigmoid to the logistic regression.

6
New cards

Sigmoid function

This is help in calssifying the data with boundaries

Its range is 0 to 1.

7
New cards

Formula of sigmoid

8
New cards

How Logistic Regression Handles Classification Problems:

Logistic regression is a linear model that predicts probabilities for binary or multi-class classification problems. Instead of fitting a straight line, it uses the logistic (sigmoid) function to map the output of a linear equation to a probability range between 0 and 1.

<p>Logistic regression is a linear model that predicts probabilities for binary or multi-class classification problems. Instead of fitting a straight line, it uses the logistic (sigmoid) function to map the output of a linear equation to a probability range between 0 and 1.</p><p></p>
9
New cards

Maximum Likelihood Estimation (MLE) vs Maximum a Posteriori Estimation (MAP):

MLE is purely data-driven, while MAP combines data with prior knowledge (e.g., from past observations or expert opinions).

<p>MLE is purely data-driven, while MAP combines data with prior knowledge (e.g., from past observations or expert opinions).</p>
10
New cards

what will be the output for each different z values

z = infintire then op is 1

z = 0 then op is 0.5

z = infinite then op is infinite

11
New cards

if we have 2 classes then its called

Binary classification

Ex : Dog 🐶 & Cat 🙀

12
New cards

when we have a lot of classes

Multiclass classification

13
New cards

multip label classification

we can see many label in same images

14
New cards

Type 1 vs Type 2

knowt flashcard image
15
New cards

random state

This will give the distribution of data each time the same.

16
New cards

Hyperparameter tuning of the losgistic regression

  • Grid search cv This will find the best parameters . But this take long time

  • Random Search Cv - This will take less time as this just take sample of data.

17
New cards

How will you measure goodness of fit for logistic regression ?

Confusion Matrix and Classification Metrics

18
New cards

Softmax

multiclass classification algorithms used by logistic regression.

Algorithm/Context

Role of Softmax

Multinomial Logistic Regression

Converts logits into probabilities for multiple classes.

Neural Networks (e.g., CNNs, RNNs)

Used in the output layer for multiclass classification.

Natural Language Processing (NLP)

Converts model outputs into probabilities for text classification.