Evidence of biological recovery from gross pollution in English and Welsh rivers over three decades

• Public concern about rivers necessitates contemporary evidence on ecological quality. • Routine river macroinvertebrate monitoring provides vital evidence at a national scale. • Macroinvertebratecommunitiesindicated quality improvements over 29 years. • Taxonomic richness increased in the 1990s, with weaker evidence for a post-2015 gain. • Improvements were widespread, but greatest in urban areas.


Introduction
Freshwaters support disproportionately high biodiversity relative to their global surface area, but are at risk from multiple stressors ranging over pollution, morphological alteration, flow modification, invasive nonnative species and human overexploitation (Balian et al., 2008;Strayer and Dudgeon, 2010).In many cases, these pressures on freshwater ecosystems are a reflection of the land use, management practices and other activities carried out within their catchments (Allan, 2004;Fierro et al., 2017).Activities such as water abstraction, flood defence, flow regulation and impoundment also have direct impacts (Lowe et al., 2019;Ward and Tockner, 2001).These stressors are further exacerbated and complicated by climate change (Charlton et al., 2018;Jeppesen et al., 2010;Moss, 2011), as thermal regimes and discharge patterns change.Taken together, these pressures have been implicated in steep declines in freshwater biodiversity, such as an estimated 83 % global decline in the abundance of freshwater vertebrates monitored since 1970 (WWF, 2022).
In contrast to this global picture of consistent decline, recent studies of freshwater invertebrate biodiversity reveal a more complex situation.Some studies have shown large declines in invertebrate abundance and diversity (e.g.Sánchez-Bayo and Wyckhuys, 2019;Stepanian et al., 2020), whilst others have revealed substantial increases in recent decades (e.g.van Klink et al., 2020;Outhwaite et al., 2020;Vaughan and Ormerod, 2012)o r mixed responses through time or between different diversity measures (e.g.Baranov et al., 2020;Pilotto et al., 2020).Trends often vary geographically, even among nearby locations (e.g.Vaughan and Ormerod, 2012;van Klink et al., 2020), but where broad scale improvements have been identified, these have often been linked to legislation aiming to reduce gross river pollution (e.g. the European Union's Urban Wastewater Treatment Directive or the Clean Water Act in the USA).Other factors implicated in long-term trends include climate and land use (e.g.Cardoso et al., 2020;Floury et al., 2013;van Klink et al., 2020;Mouton et al., 2022), and the potential for complex interactions among them (Birk et al., 2020).Where community composition or, less commonly, ecological traits or functional diversity are considered, further changes may be revealed that are overlooked by simple summaries based on species richness or biomass (e.g.Vaughan and Ormerod, 2014;Larsen et al., 2018;Mouton et al., 2022).Given the important role that invertebrates play in riverine food webs and ecosystem functioning (Yang and Gratton, 2014), coupled with their efficacy as indicators of environmental quality (Bonada et al., 2006;Friberg et al., 2011;Hodkinson and Jackson, 2005), appraising their long-term trends is a priority.
In the UK, there is widespread concern that river quality may be declining (e.g.House of Commons Environmental Audit Committee, 2022; Anon, 2021) after a documented period of biological recovery in the 1990s and early 2000s (Vaughan and Ormerod, 2012;Outhwaite et al., 2020), making an updated national scale analysis of river macroinvertebrates important.Over the last decade, attention to the changing status of the UK's rivers has grown, with some indicators revealing potential issues with combined sewer overflows and intensifying agriculture (e.g.Cockburn, 2021;Laville, 2020;Stallard, 2022).Alongside this, concerns around emerging contaminants, climate change and cumulative stressors have increased as new data have become available (Reid et al., 2019).Recent analysis of water chemistry has revealed contrasting trends for different pollutants, with some long-term improvements, for example reductions in sanitary waste, but also areas of ongoing concern (Whelan et al., 2022)whichmay have exhausted or negated the ecological benefits of past water quality improvements (Vaughan and Gotelli, 2019).Most notably, previous studies suggested a slowing in recovery in the late 1990s or early 2000s (Vaughan and Ormerod, 2012;Outhwaite et al., 2020), so there is a need to establish whether this has continued, or was simply a pause in recovery or prelude to decline.Moreover, recent research points to subtle declines in functional diversity (e.g.Larsen et al., 2018) which may be overlooked by assessments restricted to taxonomy.
In this paper, we investigate trends in the river macroinvertebrate communities of England and Wales over 29 years (1991-2019 inclusive), using a network of nearly 4000 survey locations.The work extends the time frame of previous research (Vaughan and Ormerod, 2012;Outhwaite et al., 2020) by around 10 years to update national trend estimates.We improve upon methodology used by Vaughan and Ormerod (2012), reducing biases in the data to make the analysis more representative of English and Welsh rivers as a wholein particular smaller waterbodies, which are often overlooked (Riley et al., 2018;Seager et al., 2012).We characterise biodiversity changes in enhanced detail, including functional and betadiversity, and analyse long-term change in relation to stream type and catchment land cover.We predict that: 1. Taxonomic and functional richness, the prevalence of pollutionsensitive taxa and the prevalence of a suite of 'clean-water' ecological traits, will have remained stable over the last 10-15 years, continuing the deceleration or cessation of change observed in the late 1990s/ early 2000s (Vaughan and Ormerod, 2012;Outhwaite et al., 2020).This will be reflected in a decline and then stabilisation in inter-annual variation in invertebrate communities, leading to more consistent community compositionboth taxonomic and functionalthrough time.2. Increases in richness and the prevalence of sensitive taxa will be greater and continue for longer within more heavily urbanised catchments, as they have been more polluted historically leading to greater scope for recovery.This in turn will result in rivers becoming more homogenous at a national scale through time, as the communities in recovering urban streams converge on those in historically less polluted rural areas.

Macroinvertebrate data
Macroinvertebrate data collected over 29 years (1991-2019 inclusive) by two British environmental regulatory organisations, the Environment Agency and Natural Resources Wales, were collated for English and Welsh rivers.The data were filtered to include only samples collected in spring (March-May inclusive) using a standardised, 3-min kick-sampling protocol, and subsequently sorted and identified in the laboratory to mixed taxonomic resolution.March-May was the most frequently used sample period, so this choice maximised the sample size in space and time, whilst minimising the risk of artefacts caused by variation in sample timing across the study period.A joint quality-assurance scheme for England andWales (1991-2011) indicated that the error rate was nearconstant (Murray-Bligh and Griffiths, 2022), and similar protocols remained in place subsequently for sample processing in the two countries.Sampling sites were included if they: i) had been sampled in at least four years during 1991-2019, including at least one sample in each decade (1991-2000, 2001-2010 and 2011-2019); ii) were not directly downstream from an effluent outfall; iii) included data on altitude, distance from source and channel slope; and iv) could have their catchments delineated from a digital terrain model.Criterion (i) represented a trade-off between maximising the number of sampling sites and temporal coverage within sites, whilst minimising site turnover in the data set.Catchments were delineated from a 50-m resolution digital terrain model (OS Terrain 50, Ordnance Survey) using ArcHydro tools (ESRI ArcGIS 10.7.1), apart from a small number of instances (e.g.where the drainage network had been modified and included loops).This filtering process left a total of 47,009 samples from 3982 sites, representing a mean of 11.8 years sampled per site (Fig. 1).Although the overall national sampling effort declined between 1991 and 2019, there was little change in sampling effort at the 3982 sites over time (Supplementary Fig. 1).
Data were reduced to 78 composite and family groups to eliminate any effects of changes in taxonomy or the varying taxonomic resolution to which samples were identified to ensure consistency through time (see Vaughan and Ormerod, 2014; Supplementary Table 1).Similarly, most analyses used presence-absence rather than abundance data due to variation in how abundance was recorded and for consistency with previous studies.Taxon abundances were recorded as either raw counts or placed in log 10 abundance classes (e.g.1-9a n d1 0 -99 individuals).To use abundance, all data were harmonised into log 10 classes and converted to the midpoint for each class (e.g. the abundance for taxa in the 1-9 class was recorded as 5).

Macroinvertebrate metrics
Four main metrics were used to summarise the macroinvertebrate community: i) family-level richness, ii) the first axis from a correspondence analysis (CA1) to summarise the major variation in taxonomic composition, iii) functional richness to capture the diversity of ecological traits, indicating the volume of niche space occupied by the community (Mason et al., 2005), and iv) the first axis from a fuzzy correspondence analysis (FCA1) to summarise the major variation in functional composition.
Correspondence analysis of taxonomic data was run with R's vegan package (Oksanen et al., 2020), repeating the analysis for presenceabsence and abundance data, producing CA1 PA (eigenvalue = 0.260, explaining 9 % of the variance) and CA1 Ab (eigenvalue = 0.496, explaining 6 % of the variance) scores respectively (see Supplementary Fig. 2 for the loading coefficients).This, and all other analyses in this paper, were carried out in R v4.0.1 (R Core Team, 2021).We also calculated the average score per taxon (ASPT) of the families present according to their BMWP weightings as a measure of overall sensitivity to organic pollution (Armitage et al., 1983).
Functional richness and community trait composition used six traits that focused on food and habitat preferences to capture families' potential roles in macroinvertebrate communities (i.e.'effect' traits, sensu Suding et al. ( 2008)): maximum size, feeding habit, food, locomotion and relation to substrate, preferred current velocity and preferred substratum (Tachet et al., 2010;Supplementary Table 2).Genus-level data on traits were downloaded from freshwaterecology.info (Schmidt-Kloiber and Hering, 2015) in the form of affinities (weights) for the subcategories within each of the six traits.These were converted to family-level traits by calculating each family's mean affinity for each subcategory from its constituent genera, weighting each genus by its relative abundance across the 2505 samples that formed the original RIVPACS calibration data for the UK (Monaghan and Soares, 2012;Wright et al., 2000).Affinities were then re-scaled so that the sum of the subcategories within each trait summed to one for each family (Vaughan and Ormerod, 2014).This was possible for 73 of the families which formed this part of the analysis (Supplementary Table 1).Functional richness was calculated using the dbFD function in the R package FD (Laliberté et al., 2015), based on Pavoine et al.'s (2009) dissimilarity metric calculated with the ade4 package (Dray and Dufour, 2007).Cailliez correction for negative eigenvalues was specified, and four principal coordinate analysis (PCoA) axes selected using the methodology of Maire et al. (2015).The quality of the resulting functional space was 0.496.A few samples (0.7 %) had to be removed where the number of taxa present was less than the number of PCoA axes.In a second stage, changes in average trait composition were summarised in two ways.First, community weighted means were calculated for all traits using dbFD, based on the presence-absence data (i.e.families had equal weightings).Secondly, fuzzy correspondence analysis was performed using the dudi.fca function in ade4 to provide an overview of change equivalent to the taxonomy based correspondence analysis.Again, just the first axis (FCA1), explaining 30.5 % of the variation, was retained.

Trends in invertebrate assemblages
Temporal trends in taxonomic and functional richness, taxonomic and functional CA1 scores, community weighted traits and ASPT scores were estimated for the time period 1991-2019 using generalised additive models (GAMs), fitted using R's mgcv package (Wood, 2011).The approach followed Vaughan and Ormerod (2012, 2014), using Fewster et al.'s (2000) methodology for estimating smoothed trends after first weighting individual sampling sites to adjust for bias in the sample site locations (see below for details of the weights).This step was required because macroinvertebrate sampling locations underrepresented smaller, steeper headwaters, and tended to be concentrated at slightly lower altitudes and with higher catchment urbanisation (Supplementary Fig. 1) when compared to the stratified-random River Habitat Survey (RHS) Baseline of England and Wales 2007-2008(Seager et al., 2012).
Modelling of temporal trends comprised three stages.Firstly, the probability of a river reach being sampled for macroinvertebrates was modelled as a function of a range of environmental variables.Secondly, sites had post-stratification weights calculated according to their probabilities of being sampled and thirdly GAMs were fitted to model long-term invertebrate trends using the post-stratification weightings.This process reduced biases by, for example, weighting macroinvertebrate sites in relatively under-sampled headwater streams more heavily in the GAMs.In the first stage, the 3982 invertebrate sites were combined with 4104 RHS Baseline sites located across England and Wales, and a binomial GAM was used to predict the probability of a river reach being sampled for macroinvertebrates (i.e.being an invertebrate site, rather than RHS site, in the combined data set) based on 12 environmental variables that correlate with variation in invertebrate communities (Booker et al., 2015;Clapcott et al., 2012;Dunbar et al., 2010;Leathwick et al., 2011): i-iii) the percentage of urban or sub-urban landcover (pooled in this analysis as urban), improved grassland or arable agriculture calculated from the 1 km resolution UK Land Cover Map 2007 (Morton et al., 2014); iv) the proportion of each catchment underlain by calcareous geology from 1:625,000 scale maps (British Geological Survey/Natural Environment Research Council); v) mean annual precipitation in each catchment -calculated from 1961 to 1990 averages mapped at 5 km resolution (UK Meteorological Office, Exeter, UK; Perry and Hollis, 2005); vi-vii) specific stream power (W m −2 ) and the base flow index (BFI) estimated following Vaughan et al. (2013); viii) catchment area; ix-x) elevation and channel slope at the sampling location; and xi-xii) the easting and northing of the sampling location.BFI is the proportion of the river runoff derived from stored sources, and indicates how the discharge of a river may be influenced in periods of drought (Bloomfield et al., 2009).Stream power has been shown to be a good predictor of the physical habitat within the channel, including the predominant substratum ( Vaughan et al., 2013).In the GAM, all variables were modelled as cubicregression splines, with easting and northing modelled as a tensor product smooth, with the smoothness selected by generalised cross validation (Wood, 2011).Predicted probabilities of macroinvertebrate sampling were generated for the 8086 macroinvertebrate and RHS sites.
In the second stage, predicted probabilities of macroinvertebrate sampling acted as propensity scores which were used to calculate poststratification weights for each site (Rosenbaum andRubin, 1983: Little, 1993).The RHS Baseline sites were divided into five adjustment cells based upon the quintiles of predicted probabilities.From that classification, the proportion of England and Wales's river network length within each of the five adjustment cells was calculated by: i) measuring the river length within the strata used for RHS sampling (rivers shown on the 1:250,000 scale network and additional headwaters represented only on 1:50,000 scale maps, both within each 10 km national grid square; Seager et al., 2012); ii) dividing this by the number of survey sites in each stratum as a measure of the river length represented by each RHS site; iii) summing these lengths for all sites within each adjustment cell at the national scale; and iv) dividing the five adjustment cell totals by the complete national river length to convert to proportions.Post-stratification weights, w, were then calculated for the macroinvertebrate sites in each adjustment cell, as w h = rP h /r h where r was the total number of invertebrate sites (3982), P h was the proportion of river length in adjustment cell h and r h was the number of invertebrate sites in adjustment cell h (Little, 1993).
In the third stage, correspondence analysis scores, taxonomic and functional richness, community mean traits and ASPT were modelled as a function of year, using cubic regression splines with sites weighted using the post-stratification weights (Vaughan and Ormerod, 2012).The models also included the 12 site and catchment level environmental covariates to account for variation in macroinvertebrate assemblages between sites (Fewster et al., 2000).The degrees of freedom (smoothness) of the year term was fixed at nine, approximately 1/3 of the number of years, as this is a good compromise between identifying long-term trends and shorter-term (multiple-year) changes (Fewster et al., 2000).Bootstrapping, including the process of calculating post-stratification weights, was used to produce nonparametric 95 % confidence limits of the trends, based on 399 bootstraps.Significant positive and negative 'change points' (inflections) in the trend were identified using bootstraps of the trends, following Fewster et al. (2000).As recommended by Hewson and Noble (2009), overall changes are quoted between the second and penultimate years of the time series (i.e. for 1992 v. 2018, rather than 1991 v. 2019), due to the lower reliability of smoothed estimates at the ends of time series.
Annual, unsmoothed estimates of taxonomic and functional richness and CA1 scores were also calculated, using identical methods to the smoothed estimates, except that year was treated as a categorical variable.

Changes in beta-diversity
A permutation approach was used to test for homogenisation of macroinvertebrate communities over time i.e. increasingly similar macroinvertebrate communities across locations.To control for variation in sampling frequency among sites, one sample was drawn at random from each site during each decade (1991-2000, 2001-2010 and 2011-2019 i.e. n = 3982 in each time window).The mean Jaccard dissimilarity was calculated among all pairs of sampling sites within each decade, and the process repeated 10,00 times, from which 95 % non-parametric confidence limits were calculated around the mean dissimilarity for each time window based on the 2.5 and 97.5 percentiles (Buckland, 1984).
To provide a simple assessment of the rate at which macroinvertebrate communities changed through time, the mean annual turnover across English and Welsh sites was calculated using the codyn package's turnover function (Hallett et al., 2016).Turnover between a pair of neighbouring years at a site is defined as: Turnover ¼ Families gained þ Families lost Total families observed in both years combined from which the national average was calculated.This was further split into its two constituents: the proportion of families gained (appearances) and lost (disappearances; Hallett et al., 2016).Sampling effects, notably imperfect detection accentuated by the presence of rare taxa, mean that there will always be some apparent turnover between samples; hence, the focus of this analysis was to look for changes in the rates of turnover, gains and losses through time, rather than their absolute values.To test for trends, the proportion of turnover, gains or losses was regressed onto year using the lm function.A slope coefficient differing from zero indicated that the rate of change increased (positive slope) or decreased (negative slope) over time, whilst the absolute values and y-intercept were ignored.

Community change versus catchment characteristics
A second set of GAMs was fitted to investigate the link between temporal changes in macroinvertebrate assemblages and river type in greater detailwhether trends differed between river types orequivalentlyhow the effect of an environmental variable such as catchment land cover might change through time.These models were similar to those used for temporal trends, but differed in two ways: i) a nonlinear interaction term was fitted between sampling year and the focal environmental variable, using a full tensor product smooth of cubic regression splines (Wood, 2011), with the degrees of freedom of the two constituent splines fixed at nine (Fewster et al., 2000), and ii) no post-stratification weighting was used because the focus was not on estimating unbiased national averages.Models were fitted for five environmental variables: urban, arable and improved grassland catchment land cover, altitude and catchment area, and focused on taxonomic richness and CA1 PA scores for brevity.The relationships were visualised using perspective plots and predictions of temporal trends at 'low' and 'high' values of the environmental variable (1st and 99th percentiles; Harrell, 2001).

Trends in invertebrate assemblages
Based on the smoothed, post-stratified estimates, macroinvertebrate richness increased by 9 % over the period 1992-2018, equivalent to an additional 1.5 taxa on average per site (17.3 to 18.8 taxa; Fig. 2a).The greatest increases occurred in the years 1991-1995 and 2015-2019, with little change in between.In 1995 there was a significant inflection in the trend, marking the end of the initial period of increase, but the post-2015 inflection was not significant.
The first axis from the correspondence analysis (CA1 PA ) represented the major gradient in macroinvertebrate communities, from those containing greater proportions of relatively pollution-tolerant taxa, associated with slower flows and siltier substrata, such as oligochaetes and molluscs (negative CA1 PA values; Supplementary Fig. 2a), to communities characterised by pollution sensitive taxa associated with faster flows and greater oxygenation, such as families from the Ephemeroptera, Plecoptera and Trichoptera (positive scores).CA1 PA increased across the study period (Fig. 2b), indicating greater prevalence of pollution-sensitive taxa: this was also confirmed by an increase of ~0.6 in the ASPT score over the same period (Supplementary Fig. 3).There were three relatively clear peaks and troughs around the overall trend before c. 2014, each associated with significant turning points.Re-running the analysis using macroinvertebrate abundance data (CA1 Ab ; Supplementary Figs.2b and 4) resulted in a similar overall increase and change in composition, although the timing of the peaks and troughs differed slightly from CA1 PA .Compared to 'naïve' estimates that ignored potential biases arising from the non-random selection of sampling sites, the post-stratified trends indicated smaller gains in both richness (1.5 taxa cf.1.8 un-adjusted, 1992-2018) and CA1 PA (0.14 units cf.0.18 unadjusted, 1992-2018; Supplementary Fig. 5).
There was little net change in functional richness (Fig. 2c).It increased by 10-15 % in the 1990s, declined by around 20 % by 2010-15, before increasing in the final five years, similar to taxonomic richness (Fig. 2a & c).There were no significant change points in the trend line.Positive values of FCA1 represented a greater prevalence of larger bodied organisms, those with preferences for slower flows and finer substrata (e.g.silt, mud), and predatory or parasitic invertebrates, whilst negative values were associated with organisms with small-medium body sizes, preferences for faster flowing conditions and coarser substrata, and greater prevalence of shredders, scrapers and organisms feeding on fine detritus (Supplementary Table 2).In contrast to functional richness, FCA1 showed a near-linear decline across most of the time series (Fig. 2d), with modest fluctuations around the trend that were synchronised with changes in taxonomic composition (CA1 PA ; Fig. 2b).Long-term trends were observed in many of the underlying community mean traits, albeit the absolute changes were modest (Supplementary Fig. 6).
On average, 35-40 % of invertebrate families differed between samples in consecutive years at individual sampling sites (Fig. 3b).Gains and losses occurred at similar rates, consistent with much of this turnover being a sampling effect generated by the low capture probabilities for rarer taxa in individual samples.More importantly, the rate of turnover declined at around 1 % per decade (Fig. 3b; slope = −0.0014,r 2 =0 .4 5 6 , p < 0.001), indicating a gradual increase in persistence (sensu Pimm, 1984) a facet of ecological stability.Inter-annual losses showed no overall trend (slope = −0.0001,r 2 =0.006,p = 0.69), whereas gains declined through the time period (slope −0.0012, r 2 =0 .3 8 ,p< 0.001), explaining the higher turnover in the 1990s.

Community change versus catchment characteristics
Temporal changes in invertebrate communities differed between rural and urban catchments (Fig. 4; Supplementary Fig. 7; Supplementary Table 3).More heavily urbanised catchments had lower CA1 PA scores and taxonomic richness throughout, but the gap to rural rivers narrowed through time as the most heavily urbanised catchments gained ~6 families (cf.~2 in rural catchments; Fig. 4a) and showed slightly larger increases in CA1 (Fig. 4b; Supplementary Fig. 6).Increases in both richness and composition continued until 2019 in urban catchments, whereas rural rivers showed little change after 2010.
Agricultural catchments dominated by arable or improved grassland land cover had a lower prevalence of pollution-sensitive taxa than catchments made up of less agricultural land cover, although richness was similar to less agriculturally managed catchments (Supplementary Fig. 7).Richness and CA1 PA increased at both low and high values of arable and improved grassland landcover, although changes appeared more variable through time for richness.Richness gains were greater in less agricultural catchments, whilst CA1 PA increased slightly more within the least agricultural catchments.Richness and CA1 PA varied more through time at higher than lower altitude locations, but there was little difference in net change 1991-2019 (Supplementary Fig. 7).Increases in CA1 were greater in larger rivers, with big gains pre-2000, whilst smaller catchments gained taxa steadily across the study period.

Discussion
Assessments of large-scale, long-term macroinvertebrate trends are only made possible by extensive riverine monitoring over decadal timescales.Whilst studies within individual river systems are valuable, analysing the status of rivers nationally or internationally allows conclusions to be drawn at policy-relevant scales.This approach is not without challenges.In the case of England and Wales, data collected in the 1990s and early 2000s often had limited taxonomic resolution (i.e.family-level) and sampling has traditionally been biased towards particular river types, for example underrepresenting headwaters (Supplementary Fig. 1).With careful site selection and statistical methods to minimise bias, however, it is possible to provide more accurate assessments of current status and temporal trends, as we have done for England and Wales.The post-stratification approach could be readily applied in other regions, using GIS to extract land cover, topographic and other environmental variables at the biological sampling locations and across a carefully designed, less biased sampling scheme for the river networks of interest.This, in turn, should improve the evidence base on which to appraise the status of freshwaters and macroinvertebrates across Europe and globally.
This study revealed the dynamic nature of English and Welsh rivers over three decades, most notably a 9 % increase in mean macroinvertebrate richness per site (1992-2018) and a large shift towards families characteristic of cleaner water, with associated changes in the prevalence of different ecological traits.Contrary to Prediction 1, gains of pollution-sensitive taxa  continued across the full time period, albeit at a slower rate over the last ~10 years with CA1 PA .Conversely, gains in richness stalled around 1995-2015, consistent with our prediction, before showing some evidence of an increase post-2015.This increase was not evident in an earlier analysis of English rivers (Pharaoh et al., 2021), perhaps indicating that improvements within Welsh rivers may lag behind those in England.Despite the ongoing changes, there was a small decrease in the turnover ratecommunity composition became more consistent through timewhich combined with the richness and CA1 results may indicate that recovery is gradually slowing down, perhaps as the main improvements from existing legislation, and wastewater handling and treatment are exhausted.Unless recovery is complete, new initiatives may be needed to extend these improvements (e.g.revisions to the EU's Urban Wastewater Treatment Directive;European Commission, 2022).
Increases in richness and CA1 PA continued up to 2019 in heavily urbanised catchments, fitting with Prediction 2, although there was only a slight increase in homogeneity.Increasing homogeneity, trends in richness and CA1 scores, alongside the greatest changes in the most urbanised catchments are consistent with water quality improvements in the most polluted locations narrowing the gap in quality to more rural rivers.The impact of urbanisation on rivers is well studied, and urban rivers have long been characterised by macroinvertebrate communities made up of species adapted to less favourable conditions (Chadwick et al., 2006;Roy et al., 2003;Urban et al., 2006;Walsh et al., 2005).Long-term improvement in these rivers indicate diminishing pressures through time, driven by legislation targeted largely at urban areas (e.g. the Urban Wastewater Treatment Directive 91/271/EEC) which have led to substantial reductions in gross organic pollution (Council of European Communities, 1991;Whelan et al., 2022).Despite this, rural catchments continue to support higher richness and a greater proportion of pollution sensitive taxa than their urban counterparts.
Our results for taxonomic richness and composition are consistent with an earlier analysis of national monitoring data covering 1991-2008 (Vaughan and Ormerod, 2012).Although the estimated increase in richness in the current study is smaller than that estimated in the 2012 study (9 % v. 20 %), direct comparison of these values is not appropriate due to methodological differences.This study excludes the first and last years' values from calculated percentage change, as GAMs provide less reliable estimates at the ends of time series (Hewson and Noble, 2009).This produces a more conservative figure, whereas if these years were included a 15 % increase would be reported.Despite a shared geographical coverage and similar post-stratification procedures, differences in methodology and site selection further complicate these comparisons.Due to the inclusion of more sample sites in this analysis and post-stratification using the second RHS baseline, which better represented smaller headwater streams, this new analysis should be more representative of English and Welsh rivers as a whole (Seager et al., 2012).The changes in richness are also consistent with an analysis of freshwater invertebrate data from UK recording schemes and societies covering 1970-2015 (Outhwaite et al., 2020).This found a rapid increase in the prevalence of many freshwater taxa in the early 1990s, which appeared to plateau around 2005.Notably, Outhwaite et al. ( 2020) revealed a large-scale decline prior to the 1990s, placing the more recent changes in a wider context and emphasising the importance of the choice of baseline year when interpreting long-term trends (Baranov et al., 2020).Macroinvertebrates respond rapidly to changing environmental conditions (Vaughan and Gotelli, 2019), suggesting that these historical changes were responses to contemporaneous changes in the river environment (e.g.water chemistry or land use).
The contrasting trends between taxonomic richness and composition (CA1 PA ) re-emphasises the importance of using multiple measures to assess biodiversity trends, as single metrics such as taxon richness may overlook more subtle changes (Larsen et al., 2018).Despite little change in overall richness through the mid portion of the time series, there was a large change in composition, reflecting a mixture of families increasing and decreasing, and ongoing changes in the prevalence of ecological traits.Composition may also be more sensitive to climatic variation: the fluctuations observed in CA1 (cf.richness) around the overall trends are likely attributable to climatic variability, such as that captured by the North Atlantic Oscillation index (Bradley and Ormerod, 2001;Vaughan and Ormerod, 2014), and further highlight the dynamism of macroinvertebrate communities.
The results of the functional diversity analyses resembled the taxonomic ones in important respects, whilst also providing further insights.Functional and family-level richness showed similar changes through time, but functional richness did not show a net increase between 1991 and 2019.Instead, functional richness declined through the mid-portion of the time series (c. 1995-2010), during the same period when taxonomic richness was largely unchanged.This suggests that whilst family richness was maintained, the turnover of families present led to a reduction in niche breadth, as taxa with distinctive functional traits were lost.This may be an example where functional diversity measures are more sensitive than taxonomic ones to human activities (Mouillot et al., 2013) or it may result from lower functional diversity among pollution sensitive taxa, such that in the absence of gains in taxonomic richness, functional richness declined.Functional composition (FCA1) showed similar long-term directional changes to taxonomic composition (CA1 PA ), and the putative climate-related fluctuations around the long-terms trends in these two measures were closely synchronised.The changes in the prevalence of individual traits were largely consistent with the taxonomic changes, with a shift towards taxa preferring faster flowing water and coarser substrata matching the increased prevalence of families of Ephemeroptera, Plecoptera and Trichoptera, and the reduced prevalence of taxa such as molluscs and leeches evident in the reduced prevalence of preferences for slower flowing conditions and fine substrata.Effect traits are considered to reflect the ways through which changes in species may alter ecosystem functioning (Suding et al., 2008).Inthecaseofmacroinvertebrates, this includes freshwater macroinvertebrates providing functions such as detritus processing and energy transfer to consumers (Abonyi et al., 2018;Wallace and Webster, 1996).In this light, the changes observed across a swathe of effect traits, including diet and feeding methods, could indicate fundamental changes in the functioning of river ecosystems and provision of ecosystem services (Macadam and Stockan, 2015).This aspect needs further work, especially where better abundance or biomass data are available (e.g.Powell et al., 2023).
Invertebrate communities in predominantly agricultural catchments, both arable and improved grassland, were typical of degraded streams, similar to heavily urbanised catchments.Temporal changes in invertebrate communities differed across the agricultural land use gradients, suggesting that agricultural impacts did not remain consistent through time, akin to urbanisation.Agriculture is cited as one of the most common reasons preventing rivers from achieving good ecological status (Lemm et al., 2021;Schürings et al., 2022), but its impacts will vary with land management practices, stocking type/density, agrochemical use and other factors that warrant further research (Hooda et al., 2000;Wijesiri et al., 2018).Quantifying agricultural intensity at large spatial scales is a challenge and needs to move beyond the simple measures of catchment land cover used here.Specifically, some agricultural practices, such as intensive livestock units which have become increasingly controversial (Caffyn, 2021), would not be reflected by assessments involving catchment land cover.
Although evidence gathered in this study can help to appraise actions aimed at improving the status of rivers, further work is required to identify the drivers in detail and to better understand the interactions among multiple stressors.The major role of catchment land use, and how its importance may be changing through time, has been highlighted here, but understanding the proximate mechanisms by which it impacts organisms is needed for developing management prescriptions.Other potential drivers need also to be considered, including invasive non-native species such which can affect riverine communities both directly (e.g. via predation or competition) and directly (e.g.modifying physical habitat; Gallardo et al., 2016).Furthermore, national-scale increases in richness and gains in pollution-sensitive taxa may disguise localised declines or those associated with particular river types, such as some upland rivers, chalk streams or locations affected by failing water infrastructure (O'Neil and Hughes, 2014;Vaughan and Ormerod, 2012).Research into what is driving trends across these areas will be essential for identifying locations where a more targeted approach to achieve biological recovery could be utilised.This will be of particular use in an era of changing environmental policy, legislation and investment (Burns et al., 2019;Klaar et al., 2020).

Conclusion
Our results are consistent with biological recovery of English and Welsh rivers continuing over 30 years.Recovery was greatest within urban rivers, where improvements in sanitary water quality and biota have been well documented, but improvements were also observed in rural catchments.This highlights the need for a better understanding of the drivers of change in rivers to identify potential management interventions to improve ecological quality further.At the same time, previous work has demonstrated regional differences in macroinvertebrate trends beyond simple land cover relationships (Vaughan and Ormerod, 2012), and it is likely that the national trends presented here disguise localised declines.Together, these represent two research priorities to improve our understanding of national scale changes in river quality.

Fig. 1 .
Fig. 1.Locations of macroinvertebrate sites included in the calculation of temporal assemblage trends (n = 3982 sites).Map contains OS data © Crown copyright and database right (2021).

Fig. 2 .
Fig. 2. Invertebrate trends for England and Wales in the years 1991-2019, represented by (a) invertebrate family richness, (b) CA1 scores from presence-absence data (CA1 PA ), (c) functional richness and (d) FCA1 scores of ecological traits.Smoothed post-stratified estimate displayed as solid black line, with dotted lines and shaded area indicating 95 % confidence limits, and black points denoting annual unsmoothed post-stratified estimates.Coloured dots along the smoothed line represent statistically significant inflections in the gradient of the curve: red indicating reduced rate of increase or greater rate of decline, and blue indicting greater rate of increase or reduced rate of decrease.(For interpretation of the references to colour in this figure legend, the reader is referred to the web version of this article.)

Fig. 3 .
Fig. 3. a) Community similarity of invertebrate families in samples collected in the years 1991-2000, 2001-2010 and 2011-2019 measured as mean Jaccard dissimilarity.The inset shows the changes on the full 0-1 dissimilarity scale, whilst the main figure enlarges part of this range to show the variation within each group.b) Mean invertebrate family turnover in the years 1991-2019.Total family turnover (blue line) is made up of family appearances (green) and disappearances (amber).Relationship between mean invertebrate family turnover and year (1991-2019) based on linear regression (dashed line).(For interpretation of the references to colour in this figure legend, the reader is referred to the web version of this article.)