Predicting Self-Harm Events After Emergency Department Visits Associated With Mental or Substance Use Disorder Diagnoses
Objective Using a machine learning model, the authors aimed to predict self-harm events within 90 days of an emergency department (ED) visit associated with a mental or substance use disorder diagnosis. Methods Electronic health record and claims data of patients ages ≥11 years from seven integrated health systems were used to identify ED visits and diagnoses. Data on 1,254 predictors were extracted for the 60 months before an ED visit, and self-harm was measured in the 90 days after this visit. Logistic regress…

In brief
Researchers analyzed 1,554,828 emergency department visits by 803,413 patients aged 11 and older across seven integrated health systems. Each visit was linked to a mental or substance use disorder diagnosis, and the team used 1,254 predictors drawn from the prior 60 months of records and claims to estimate self-harm in the following 90 days.
The findings suggest that routinely collected data can flag which patients leave the emergency department at greatest risk, potentially guiding limited follow-up resources. The abstract describes the tool as potentially useful rather than demonstrating that using it reduces self-harm, so its effect on patient outcomes remains untested here.
Main points
- Self-harm occurred after 19,603 visits, or 1.3% of the 1,554,828 visits studied.
- The best-fitting model reached an area under the curve of 0.85, with performance consistent across various subgroups.
- Visits at the 95th percentile of predicted risk had a 10.8% self-harm rate, versus 2.4% at the 50th percentile.
- The highest risk stratum had an observed self-harm risk of 27.2%, about 136 times that of the lowest stratum.
The gain
A machine learning model using health record and claims data separated emergency department patients by 90-day self-harm risk, which could help target safety planning and follow-up after discharge.
The rundown
The study drew on electronic health record and claims data from seven integrated health systems. It covered patients aged 11 and older whose emergency department visits were associated with a mental or substance use disorder diagnosis, with predictors extracted from the 60 months before each visit.
Logistic regression models estimated self-harm events, and performance was assessed using out-of-sample cross-validation predictions. Self-harm was measured in the 90 days after each visit.
The authors conclude that such models could help identify patients who may need safety planning and close follow-up after discharge.
Sources
- Peer-reviewedPsychiatric Services2026-10-14
ace
The debate