Machine learning with Rotamap data
Alexander Bones, July 2026
Summary
We explore how data from Rotamap systems can be used for predictive analytics to forecast the future and plan for different situations. As an example, we predict additional spend and how that might change under industrial action. Future developments will build on this work to provide predictive models to improve planning and deliver cost savings for a more efficient health service.
Introduction
At Rotamap, we are keen to make the most of the data within our systems, and to make data extraction as seamless as possible. With our Report Builder and Central API, users can extract data according to their exact needs, and set up automated data extraction processes. Now that data provision is easier, the problem becomes making sense of the vast amount of available data.
Hospitals and other care environments are incredibly complex, therefore it is vital to understand how different aspects of the organisation come together to influence our outcome of interest. In rostering, for example, the use of additional paid (extra) sessions can happen for a huge number of reasons. Perhaps leave guidelines weren't followed and too many people were on leave at the same time, meaning that a locum worker had to be called in. Alternatively, there may have been industrial action, or a staff member may have had an accident and needs to take unplanned leave at short notice. There may be an increase in patient demand due to seasonal pressures, or a number of other factors.
In this article, we will demonstrate what is possible with data from Rotamap services, and given an idea of what the future of our data products will look like. We will explore predicted extra sessions in different scenarios as an example of what is possible. If forecasting and data analytics is something you'd like to discuss, please reach out to the Rotamap team at support@rotamap.net or +44 (0) 20 7631 1555.
Forecasting extra sessions
Extra sessions can be a substantial cost for healthcare organisations, but can often be managed with better planning to use staffing resources more efficiently. We wanted to take a look at how extra sessions might change in response to things like planned leave, unplanned leave, and cancellations. We extracted data using the Central API across five years and trained a machine learning model on this data. We then plotted the model predictions under different scenarios.
We will start with a scenario that will act as a baseline that we can then compare against when changing inputs. We will create an "average" year by taking the five year average of our model inputs (annual leave, study leave etc.) on a given day. We'll put these values into our model and see what it predicts the extra sessions will be, which we can inspect to see if they match our intuition.
The predicted extra sessions are shown in Figure 1. We can see general seasonal trends that we would expect. There are a high number of extra sessions at the start of the year, likely reflecting winter pressures and seasonal sickness. This then declines through February, then increases slightly at the end of the month. Extra sessions then reduce at the start of March, perhaps reflecting staff taking planned leave for school holidays and a reduction in planned elective procedures. It then remains relatively stable, increasing again around mid-April, before dipping around the middle of May, then increasing throughout June. This might reflect an increase of staff on break over the summer, and the need for additional funded sessions to fill the gaps.
Figure 1. Line graph of the predicted extra sessions from a machine learning model based on an "average" year. The "average" year data was created by taking the average of our input features on each day of the year across the previous five years. These values were used as inputs for the machine learning model, and the model produced a prediction for the number of extra sessions that would fall on a given day of the year.
Now that we have our baseline, we can predict what the impact is going to be if we increase unplanned leave in June to simulate industrial action Figure 2. We're going to imagine that the impact of unplanned leave will be 50 sessions. If you look at the second week of June, the model predicts a large increase in the number of extra sessions. Despite each day having 50 sessions missed due to unplanned leave, the predicted number of extra sessions is not the same across all days. This will reflect differences in numbers of sessions missed due to planned leave, study leave, as well as the day of the week. The model can determine how all of these variables relate and what the impact will be on extra sessions.
Figure 2. Line graph of the predicted extra sessions from a machine learning model under an industrial action scenario. Here, the unplanned leave was set at 50 sessions for a week in June, and the model predicted an increase in the number of extra sessions, when compared to the same time periods baseline in Figure 1.
We can also model different mitigation strategies to see if the impact of industrial action can be reduced. Let us imagine that we happen to be very lucky, and nobody in the department who isn't striking is taking any other leave. We imagine that we have around 20 additional normal sessions a day that would have been missed without this spare capacity. When we predict the extra sessions in this scenario (Figure 3), we can see that the number of extra sessions over the week has reduced substantially, from around 60 sessions per day to around 30 per day. Despite us only having an additional 20 normal sessions per day, we have a reduction of around 30 extra sessions. Here, the model has reflected historical behaviour when more staff are available in this department and there is a high number of unplanned absences, which may include moving people from non-DCC work to more urgent work under industrial action or sickness, thereby reducing the extra sessions by more than the number of normal sessions. Of course, this scenario is not incredibly realistic, but it does show how strategies could be developed to increase the resilience of the department to unexpected shocks, and what the impact of these strategies is likely to be before we implement them.
Figure 3. Line graph of the predicted extra sessions from a machine learning model under an industrial action mitigation scenario. Here, we reduced all planned leave to 0, increased the number of normal sessions, and reduced the number of extra sessions (both by 20) to simulate having flexible capacity to cover some of the work missed due to industrial action.
We now have an idea of how data from Rotamap systems can be used to model future scenarios. Combining different data sets, such as leave, assignments, and cancellations, together, reveals more about an organisation than any single data set in isolation. To make sense of the vast amounts of data produced, it is often necessary to use modelling techniques to cut through the noise and understand the underlying "Why?" behind our area of interest. With the model described in this article, we identified which aspects of the rota correlate to the increase in extra sessions. Here, we found that unplanned leave had a large impact on extra sessions, therefore we would want to find ways for this department to address this. This is inherently difficult for unplanned leave, but we have presented a situation where the department has capacity to cover the shortfall as a result of lower planned leave. We might consider limiting the number of people who can take planned leave types at one time using leave pools within the department, to ensure there is some flexible capacity, or we might consider more flexible working arrangements to allow a similar level of cover. Rotamap are excited to enter a new realm of data provision, moving beyond asking "what happened?" to predicting the future. This will allow you to plan better in advance and identify pressure points before they happen, resulting in improved service delivery for patients.
Conclusions
Here, we have demonstrated how data from Rotamap systems can be used with machine learning techniques, and the insights that can be revealed by combining numerous data sources together. We predicted the number of extra sessions on a given day based on the number of sessions missed due to planned leave, unplanned leave, cancellations, etc., and explored ways to minimise the disruptive impact of industrial action. This is an exciting time for Rotamap. We can provide vast amounts of data on demand for users, which comes with new challenges in making sense of that data. We hope this article has explained some of the ways that data can be analysed using machine learning techniques, and gives you an idea of what the future of data looks like at Rotamap.
Disclaimer
All data used within this article were extracted from Rotamap's services and the organisations have been anonymised. Machine learning models were created using scikit-learn in Python. Visualisations were created using plotly in Python. This article is preliminary in nature and should not be used to inform design or planning of rosters, work schedules, job plans, or any other aspect of the organisation.
Contact us
If you would like to work with us to implement the Report Builder for organisation-wide reporting, would like a demonstration of the Report Builder, or would like to discuss potential data analytics work, please contact the Rotamap support team at support@rotamap.net or +44 (0) 20 7631 1555 if you are an existing user, or info@rotamap.net if you would like to learn more about Rotamap services.