Healthcare scheduling case
The Meadow Scheduling coordinator requests an offline reminder-priority evaluation. Use the fictional pre-appointment records, preserve the holdout, and deliver baseline recall, model probabilities, thresholded labels, recall and a rule-based pilot recommendation. The model must not restrict access to appointments.
Meadow Scheduling wants to prioritize optional reminder calls. Its fictional table describes information known before the appointment: prior visits, lead time and missed-visit history. Class 1 means a missed appointment. The coordinator can use a risk score to order calls, but it must not decide whether someone can book care.
Build a small evaluation record that the coordinator can inspect. Start with a seeded class-prior baseline, fit logistic regression, retain its probabilities, and evaluate labels at the stated threshold. The final recommendation is checked against the measured recall difference rather than a promise about future attendance. Keep the test rows outside fitting throughout the case. Each step continues your notebook, and later outputs add new evidence instead of passing on an unchanged earlier result.
baseline_model = DummyClassifier(strategy="stratified", random_state=31).fit(X_train, y_train)
baseline_recall = recall_score(y_test, baseline_model.predict(X_test), zero_division=0)
The class-prior prediction provides a lower-effort comparison. Its recall exposes whether it finds any missed appointments.