Chris Banks
Selected projects / Veterinary diagnostics
Flagship project · 2025

ML-augmented diagnostic testing for bovine tuberculosis

We looked at whether knowing more about a herd could help us spot bovine TB earlier without raising the false-positive rate for herds.

Bovine tuberculosisHerd-level diagnosticsGreat Britain
Abstract British cattle landscape where skin-test evidence, herd histories, movements, and location data converge into a herd-level interpretationHerd evidence + context → interpretation

What else can a skin-test result tell us?

Great Britain uses the statutory SICCT skin test to monitor bovine TB. The test rarely gives a false positive in an individual animal, but even testing the whole herd can miss an infected herd. We wanted to know if other information could help us interpret the result.

We combined national test records with information about herds, their locations, and cattle movements. We trained a machine-learning model to estimate the chance of a confirmed breakdown (a herd-level outbreak of bovine TB) within 90 days of a test.[1]

The same test result can mean different things for different herds. What we do with that information depends on the priority: finding more infected herds or avoiding unnecessary restrictions.

How we used the national test records

We used every recorded whole-herd SICCT test in Great Britain from January 2012 to September 2021. We trained the model on earlier records and tested it on later ones.[1]

1.3mrecorded whole-herd SICCT test events
2012–21national testing period represented
90 dayswindow for a later confirmed herd-level outbreak
2020+reserved testing period for evaluation

Link the records

We linked each test to what was known about the herd at the time, including its location, movements, and previous results.

Estimate outbreak risk

We trained a histogram-based gradient-boosted tree model to estimate the chance of a confirmed herd-level outbreak within 90 days.

Compare thresholds

We compared different cut-offs for flagging a herd. The choice changes how many infected herds we find and how many other herds we flag unnecessarily.

Two ways to use the model

We compared two ways to use the model. One could find more infected herds at the same herd-level specificity. The other could flag fewer herds unnecessarily at the same herd-level sensitivity. Both estimates use 2020 test data that we kept separate from training. Neither changes the individual-animal skin test.[1]

Match herd-level specificity · 90.3%

Detect more infected herds

240
additional infected herds the model could have flagged earlier in one year

Result: Herd-level sensitivity rose from 63.9% to 69.0%, a 5.2 percentage-point increase at the same herd-level specificity.

These herds later had confirmed bovine-TB outbreaks. The estimate comes from the 2020 test data.

Match herd-level sensitivity

Reduce unnecessary restrictions

5,225
herds in the 2020 evaluation year with no confirmed breakdown within 90 days

Result: Herd-level specificity rose by 2.7 percentage points when we set the model to match the herd-level sensitivity of the usual skin-test interpretation.

There was no further evidence of infection in these herds within 90 days. Our analysis suggests they could have avoided unnecessary restrictions under this threshold.

What the model learnt about risk

We looked at which herd and landscape factors contributed most to the model’s predictions.

Herd size

How many animals were tested helped the model predict later outbreaks.

APHA risk score

The risk score already assigned to the herd helped the model make its prediction.

Movements

Recent arrivals gave the model information about possible exposure.

Previous outbreak

The model took account of how long it had been since a previous outbreak.

Location

The herd’s location helped the model distinguish higher- and lower-risk herds.

Previous result

Earlier test results helped the model interpret the latest one.

What we want to test next

We tested the model on past records. We now want to know how it would work on farms, whether people would find it useful, and whether the approach could help with other diseases.

Usability and trust
1

Make predictions useful to farmers

Find out whether we can avoid unnecessary restrictions and their costs, and explain to farmers why the model flagged a herd.

Field testing
2

Test the model in the field

Seek funding to test the model during routine herd testing and find out whether it changes decisions or improves outcomes.

Other diseases
3

Try the approach with other tests

Start with Scotland’s BVD check test, which screens a sample of animals for evidence that the herd has been exposed. Then look for other diseases where the approach might help.

A field trial would tell us whether the model improves decisions. Before it could be used routinely, people would also need to know when to use it and how to interpret its predictions.

Who worked on the study

Rowland Kao and I developed the approach from an earlier proof of concept. I carried out the analysis and led the paper. Rowland and I interpreted the findings together, with feedback from colleagues at Defra and the Animal and Plant Health Agency.

Chris BanksAnalysis, software, modelling, interpretation, and paper leadership
Rowland KaoProject development, epidemiological interpretation, and supervision
Defra and APHADomain-expert feedback and policy context
Research teamPaper authorship, data contributions, and supporting expertise

The published work was supported by the GB bovine-TB research budget and Roslin Institute/BBSRC funding.[1]

Paper, code, and slides

You can read the paper and download the analysis code. The surveillance and cattle-movement records are held under a data-sharing agreement.

Code
Published analysis code on Zenodo ↗

Archived code associated with the peer-reviewed article.[3]

Slides
Machine learning augmented diagnostic testing ↗

Directly relevant project presentation.[4]

Data
Available through the data owners

APHA surveillance and Cattle Tracing System data were supplied under a data-sharing agreement. Requests are handled by the relevant data owners.[1]

Next project

Land-use change, deer–cattle contact, and infection risk

View the environmental-risk project →