⭐ Star
0%
MODULE 06 ⏱️ 15-22 MIN READ

Logistic Regression, ROC-AUC & Classification Metrics

Model binary class probabilities via log-odds, Maximum Likelihood Estimation, and evaluate imbalanced datasets.

1. The Logit Function & Sigmoid Activation

Logistic Regression models the log-odds of a positive class as a linear combination of input features:

\[ \ln\left(\frac{p}{1 - p}\right) = \beta^T \mathbf{x} \implies p = \sigma(\beta^T \mathbf{x}) = \frac{1}{1 + e^{-\beta^T \mathbf{x}}} \]

2. Confusion Matrix Metrics for Imbalanced Datasets

  • Precision: \(\frac{\text{TP}}{\text{TP} + \text{FP}}\) (Quality of positive predictions).
  • Recall (Sensitivity): \(\frac{\text{TP}}{\text{TP} + \text{FN}}\) (Completeness of positive predictions).
  • F1-Score: Harmonic mean: \(2 \times \frac{\text{Precision} \times \text{Recall}}{\text{Precision} + \text{Recall}}\).

🎯 Module Mastery Certification Quiz

+100 XP
For a medical disease detection model where missing a sick patient (False Negative) is catastrophic, which metric should be maximized?
Recall (Sensitivity)
Accuracy
Specificity
Training speed