Results

Resilience of the oxic state

The trait diversity effect on the resilience of the oxic state depended on which functional group varied in traits (Fig. 3 a-f, red lines). Resilience increased with increasing trait variation in the group that dominated the oxic state (cyanobacteria; Fig. 3a, b). In contrast, increasing diversity in the two suppressed groups either reduced resilience of the oxic state (sulfate-reducing bacteria; Fig. 3c, d) or had no effect on resilience (phototrophic sulfur bacteria; Fig. 3e, f).
Simultaneous variation in more than one functional group reduced or did not change the diversity effect of individual functional groups (Fig. 3 g-o; red lines). Simultaneous trait variation in cyanobacteria and sulfate-reducing bacteria (Fig. 3g) led to smaller diversity effects than variation in only one of these two groups; the negative diversity effect of sulfate-reducing bacteria outweighed the positive diversity effect of cyanobacteria when trait variation was low, but the effect of cyanobacteria diversity prevailed at high trait variation (Fig. 3b, d, h). Diversity in the phototrophic sulfur bacteria did not change the diversity effects of other functional groups (Fig. 3 i-o).

Resilience of the anoxic state

The diversity effect on the resilience of the anoxic state also differed among groups (Fig. 3 a-f, blue lines). The two groups that dominated the anoxic state had contrasting diversity effects on its resilience: increasing diversity in the sulfate-reducing bacteria increased the resilience of the anoxic state (Fig. 3 c, d), whereas increasing diversity in the phototrophic sulfur bacteria decreased resilience (Fig. 3e, f). Diversity in the suppressed group (cyanobacteria) had no effect on resilience when diversity was low but slightly reduced resilience when diversity was high (Fig. 3 a, b).
When more than one functional group varied in traits, their effects were either additive (cyanobacteria and sulfate-reducing bacteria) or one group erased the diversity effect of another group (Fig. 3 g-o, Supplementary Report Section 12). Specifically, variation in sulfate-reducing bacteria erased the diversity effect of phototrophic sulfur bacteria (Fig. 3 l, m), and variation in phototrophic sulfur bacteria erased the (small) diversity effect of cyanobacteria (Fig. 3 i, k).

Dynamics of strains and substrates

Trait variation led to compositional turnover along the oxygen diffusivity gradient when a functional group was on the collapse trajectory (see Box 1 for explanation of terms). Less tolerant strains were replaced by more tolerant strains as the concentration of the inhibiting substrate increased (Fig. 4). On the trajectory of decreasing oxygen diffusivity, the ecosystem was initially dominated by the cyanobacteria strain with lowest sulfide tolerance and highest maximum growth rate (Fig. 4a). As oxygen diffusivity declined, more tolerant strains of cyanobacteria replaced the fastest growing strain until the strain with highest sulfide tolerance dominated. Subsequently, the cyanobacteria collapsed, probably due to their reduced capacity to suppress the sulfur bacteria, and simultaneously the ecosystem shifted from oxic to anoxic (Fig. 4 d, e). Prior to the tipping point, the most tolerant strains of the two sulfur bacteria groups slightly increased in abundance, in particular in the sulfate-reducing bacteria (Fig. 4b). However, once the system shifted to anoxic, the sulfur bacteria strains with lowest tolerance and highest maximum growth rate dominated (Fig. 4 b, c).
Strain dynamics were similar on the trajectory of increasing oxygen diffusivity (Fig. 4). Replacement of less tolerant by more tolerant strains in both groups of sulfur bacteria was followed by the collapse of the phototrophic sulfur bacteria. Then sulfate-reducing bacteria collapsed, simultaneously with the shift from anoxic to oxic and the rise of the least tolerant cyanobacteria strain. In contrast to the trajectory of decreasing oxygen diffusivity, the switch from least to most tolerant strains occurred over a comparatively broad range of oxygen diffusivity.
The strain dynamics deviated from this pattern when there was medium to high variation in only the phototrophic sulfur bacteria. In this case, all three functional groups coexisted at low levels of oxygen diffusivity likely because high maximum growth rates in the phototrophic sulfur bacteria led to lower sulfide concentrations (Supplementary Report Section 10.2). The same pattern occurred for simultaneous variation in phototrophic sulfur bacteria and cyanobacteria, albeit only on the trajectory of increasing oxygen diffusivity (Supplementary Report Section 10.2).

Mechanisms of the functional diversity effects

At low levels of trait variation, the diversity effects were driven entirely by the most tolerant strains. At higher levels of trait variation, however, strains with low tolerance (and high maximum growth rate) also contributed to the diversity effects in five of the seven combinations (Supplementary Report Section 11). For example, in the sulfate-reducing bacteria, absence of strains with high maximum growth rates led to reduced production of sulfide and therefore to coexistence with cyanobacteria at low oxygen diffusivity. That is, high maximum growth rates often had ecosystem-level consequences.