0% found this document useful (0 votes)
10 views2 pages

Day 3, Task 2

Logistic regression is a supervised machine learning algorithm used for binary classification by predicting the probability of an outcome using a logistic function. The model can be evaluated using metrics such as confusion matrix, accuracy, precision, recall, specificity, F1 score, and AUC-ROC, each providing insights into different aspects of model performance. The choice of evaluation metric should align with the specific problem and business objectives, especially in cases of imbalanced classification.

Uploaded by

vardanyantamar22
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views2 pages

Day 3, Task 2

Logistic regression is a supervised machine learning algorithm used for binary classification by predicting the probability of an outcome using a logistic function. The model can be evaluated using metrics such as confusion matrix, accuracy, precision, recall, specificity, F1 score, and AUC-ROC, each providing insights into different aspects of model performance. The choice of evaluation metric should align with the specific problem and business objectives, especially in cases of imbalanced classification.

Uploaded by

vardanyantamar22
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

1.

What is logistic regression in what tasks is used

Logistic regression is a supervised machine learning algorithm that


accomplishes binary classification tasks by predicting the probability of an
outcome, event, or observation. Logistic regression works by estimating the
probability of the event occurring using a logistic function, which maps any
input value to a value between 0 and 1. The logistic function is a S-shaped
curve that starts from 0 and gradually increases to 1 as the input value
increases.

2. How can the model be evaluated, what indicators can be used


and what does each of them mean

Logistic regression models can be evaluated using a variety of metrics that


provide insights into how well the model is performing. Here are some
common evaluation metrics for logistic regression:

1. Confusion Matrix: A confusion matrix shows the number of true


positives (TP), true negatives (TN), false positives (FP), and false
negatives (FN) predictions made by the model. The confusion matrix
can be used to calculate several other evaluation metrics:

2. Accuracy: Accuracy measures the proportion of correctly classified


instances out of the total number of instances. It is calculated as (TP +
TN) / (TP + TN + FP + FN).

3. Precision: Precision measures the proportion of correctly predicted


positive instances out of the total number of positive predictions made
by the model. It is calculated as TP / (TP + FP).

4. Recall (also known as Sensitivity or True Positive Rate): Recall


measures the proportion of correctly predicted positive instances out
of the total number of actual positive instances in the data. It is
calculated as TP / (TP + FN).

5. Specificity (also known as True Negative Rate): Specificity measures


the proportion of correctly predicted negative instances out of the total
number of actual negative instances in the data. It is calculated as TN /
(TN + FP).
6. F1 Score: F1 score is a weighted harmonic mean of precision and
recall, and provides a balance between the two metrics. It is calculated
as 2 * (precision * recall) / (precision + recall).

7. Area Under the Receiver Operating Characteristic Curve (AUC-ROC):


AUC-ROC is a plot of the true positive rate (recall) against the false
positive rate (1 - specificity) at different probability thresholds. AUC-
ROC measures the overall performance of the model across all
probability thresholds, and is a popular metric for imbalanced
classification problems.

The choice of evaluation metric depends on the specific problem and the
business objectives. For example, accuracy may not be a suitable metric for
imbalanced classification problems, and recall may be more important than
precision for medical diagnosis tasks.

You might also like