Using Machine Learning to Predict the Course of Post-traumatic Headache

By Fred Schwaller | August 6, 2025 | Posted in

A model relying on electronic headache diary data accurately classified study participants into subgroups with different headache trajectories after a mild traumatic brain injury.

Personalized medicine approaches – tailoring treatment to particular subgroups of patients based on their unique characteristics – are a long-sought goal in many different areas of medicine. Now, a new study uses machine learning to push the headache field toward personalized medicine in the context of post-traumatic headache (PTH) in people who have suffered a mild traumatic brain injury (mTBI).

Researchers led by Catherine Chong, Mayo Clinic, Phoenix, US, used electronic diary (eDiary) data collected over three months from people with acute PTH after mTBI to train and test a machine learning model. The model accurately classified these individuals into subgroups that had distinct headache trajectories post-mTBI, sometimes needing as little as two weeks’ worth of eDiary data to accomplish that feat.

“This is an important research direction, and I am excited to see this model developed further as it has great potential in clinical care,” according to Carlyn Patterson Gentile, a researcher and physician at Children’s Hospital of Philadelphia and the University of Pennsylvania, US, in an email to Migraine Science Collaborative. “If we can predict who will have a protracted recovery, then we can intervene with targeted headache care early for those who need it and not over-treat those who don’t, with the ultimate goal of modifying their disease outcome,” according to Patterson Gentile, who was not involved with the study.

The research appeared in the July/August 2025 issue of Headache.

Identifying subgroups using a training cohort
Many people who experience mTBI may suffer from PTH, which causes pain, disability, and a substantial burden on the long-term health of those who have this type of headache, according to the authors in their paper. Around half of individuals with acute PTH will recover on their own within two to four weeks of injury, but the other half experience frequent, debilitating, and often daily headaches that can persist for years (Ashina et al., 2023). Predicting how the headaches may evolve over time remains a challenge.

“Unfortunately, there is currently no reliable way for clinicians to accurately predict if, when, and at what pace an individual patient will improve from PTH,” the authors wrote.

Previously, the researchers developed models to predict PTH improvement versus non-improvement at three months after an mTBI. However, “this binary outcome determined at three months may overlook individual variations in the progression or relapse of headaches over time,” they wrote, setting the stage for the new research.

The investigators aimed to create a new predictive model based on the diverse patterns of headache symptoms in people with acute PTH. They enrolled 73 people with acute PTH resulting from mTBI and examined the evolution of their headache symptoms for three months after study enrollment.

Participants completed an eDiary each day to track headache occurrence and severity, disability severity, and difficulty in performing usual activities and physical activities, and how the symptoms evolved over three months.

The group then used eDiary data from 54 participants to train a machine learning model that they hoped would predict people’s distinct headache evolution.

The machine learning approach allowed for the identification of four subgroups with distinct headache trajectories. Those in subgroup 1 had severe symptoms that showed no improvement over the three months, while subgroup 2 had severe symptoms with mild improvement. Subgroup 3 had milder symptoms that got substantially better, while subgroup 4 had the mildest symptoms with mild improvement.

“Overall it is a real strength of the paper to use eDiary entries for three months to train and validate their model. Many studies ask participants to recall how many headache days they have had in the past week or month, whereas this captures day-to-day fluctuations that address limitations introduced by recall bias,” Patterson Gentile said.

Interestingly, the authors found that different amounts of eDiary data were needed to classify study participants into the different subgroups. For example, just two weeks of data allowed for identification of the subgroup with the mildest headaches.

That was “the most important and convincing finding of the study, indicating they would not need more aggressive headache targeted management,” according to Patterson Gentile.

However, identifying the subgroup with the most severe headaches and no improvement required three additional weeks, and two additional weeks for the other subgroups.

Overall, the model represents a promising start for efforts to better understand the trajectory of headache in people with PTH after mTBI.

“This is an important step, though continuing to build and refine this model may help shorten the time it takes to identify those who need more aggressive headache targeted care,” Patterson Gentile noted.

Machine learning in a test cohort
Next, the authors tested if their machine learning model could predict headache evolution in a test cohort of 19 participants. The model classified individuals into the four subgroups with an accuracy of 0.84 (84%). Data from the 54 individuals in the training cohort revealed an accuracy of 0.80 (80%).

“Notably, the model accurately identified 90% of [low headache frequency] individuals in the training cohort and 100% of participants in the test cohort, demonstrating its high performance in detecting individuals with the mildest symptoms who have quick improvement,” the authors wrote.

In terms of future work, “Follow-up studies that include larger sample sizes will be needed, and these will be important next steps to develop this model for use in clinical settings to improve care, which is an important research direction in PTH,” Patterson Gentile said.

The study authors wrote that “[i]f validated, this PTH prediction model could assist clinicians with tailoring treatment strategies to individuals with PTH with different treatment needs and could assist researchers with determining the suitability of individuals for PTH clinical trials.”

Ultimately, the new research represents a promising advance in the search for personalized medicine approaches for migraine and headache. It joins other efforts that also use AI for that purpose (see MSC related podcast), as well as efforts using genetic (see MSC related article) and other strategies.

Fred Schwaller, PhD, is a freelance science writer based in Germany.

Image credit: 123RF Stock Photo.

Reference
Identifying and predicting headache trajectories among those with acute post-traumatic headache.
Mao et al.
Headache. 2025 Jul-Aug;65(7):1124-33.

Sign Up For An MSC Newsletter

Sign up for:

Fred Schwaller is a science writer and communicator based in Berlin, Germany. Fred spent a decade in pain research during his doctoral degree at University College London, UK, and his postdoc at the Max Delbrück Centre in Berlin, Germany. After transferring to science communication in 2020, he has been writing and podcasting about life sciences and medicine, specializing in somatosensation and pain. Follow him on Twitter @SchwallerFred.

Discussion

Leave a Comment

You must be logged in to post a comment.

Search

  • Content Types

  • Paper Categories

  • Paper Dates

Recent News

Recent Papers

Calendar

No event found!