Logistic regression models the probability of a binary event (0/1, Yes/No) as a function of multiple predictors. It is essential in epidemiology, medicine, and social sciences.
When to use it
Predict a binary outcome (disease/healthy, success/failure)
Calculate adjusted odds ratios
Identify risk factors while controlling for confounders
Requirements
Binary dependent variable
Continuous or categorical predictors (automatic encoding)
N ≥ 10 events per variable to avoid overfitting
What StatsLab computes
Odds Ratios (OR) with 95% CI
β coefficients and p-values
AUC-ROC with curve
k-fold cross-validation
Confusion matrix
Forest plot of ORs
Calibration curve
Worked example
Context : Predicting relapse risk (Yes/No) from 3 biomarkers in 200 patients.
Result : AUC = 0.82 · Biomarker A: OR = 2.4, 95% CI [1.6; 3.7], p < 0.001
Interpretation : Good discriminant power (AUC = 0.82). Biomarker A multiplies relapse risk by 2.4. The model is well calibrated.