Significance Many biological systems exhibit an emergent ability to process information about their environment. This collective cognition emerges as a result of both the behavior of system components and their interactions, yet the relative importance of the two is often hard to disentangle. Here, we combined experiments and modeling to examine how fish schools collectively encode information about the external environment. We demonstrate that risk is predominantly encoded in the physical structure of groups, which individuals modulate in a way that augments or dampens behavioral cascades. We show that this modulation is necessary for behavioral cascades to spread and that it allows collective systems to be responsive to their environments even without changes in individual computation.

Abstract The need to make fast decisions under risky and uncertain conditions is a widespread problem in the natural world. While there has been extensive work on how individual organisms dynamically modify their behavior to respond appropriately to changing environmental conditions (and how this is encoded in the brain), we know remarkably little about the corresponding aspects of collective information processing in animal groups. For example, many groups appear to show increased “sensitivity” in the presence of perceived threat, as evidenced by the increased frequency and magnitude of repeated cascading waves of behavioral change often observed in fish schools and bird flocks under such circumstances. How such context-dependent changes in collective sensitivity are mediated, however, is unknown. Here we address this question using schooling fish as a model system, focusing on 2 nonexclusive hypotheses: 1) that changes in collective responsiveness result from changes in how individuals respond to social cues (i.e., changes to the properties of the “nodes” in the social network), and 2) that they result from changes made to the structural connectivity of the network itself (i.e., the computation is encoded in the “edges” of the network). We find that despite the fact that perceived risk increases the probability for individuals to initiate an alarm, the context-dependent change in collective sensitivity predominantly results not from changes in how individuals respond to social cues, but instead from how individuals modify the spatial structure, and correspondingly the topology of the network of interactions, within the group. Risk is thus encoded as a collective property, emphasizing that in group-living species individual fitness can depend strongly on coupling between scales of behavioral organization.

A key challenge faced by animals is to appropriately adjust their behavioral responses to changing environmental contexts (1). To do so, organisms must make probabilistic decisions based on often imperfect or conflicting sensory information. Longer-term states such as fear or hunger can be considered as a persistent (but updatable) memory stored by the animal that modulates the mapping from sensory input to behavioral change. The mechanisms by which individual organisms achieve effective context-dependent behavior have been well studied (2⇓–4), but what has been comparatively rarely explored is how such behavioral plasticity is encoded by organisms that live in groups. In highly coordinated animal groups, such as many species of schooling fish, flocking birds, or herding ungulates, individual reproductive success is often intimately linked with the functional complexity of collective behavior (5, 6). This introduces a coupling between individual (“microscopic”) properties and collective (“macroscopic”) behavior, and it is reasonable to expect that this coupling will impact how evolution has shaped the mechanisms by which individuals sense and respond to changing environmental conditions.

For example, if we consider an individual in isolation, it must base its decisions on sensory inputs and previous experience, which may also be modulated by physiological state. However, it is clearly the individual that is “responsible” for the decision. If we consider instead individuals embedded in a social network, another possibility is introduced: As in other information-processing networks, such as neural circuits, computation may be affected by changes in the individual components themselves (network “nodes”) and/or by changes in the structural connectivity (topology) among the components (network “edges”). In animal groups, individuals often exhibit a highly dynamic group structure, with individuals’ spatial positions, orientations, and sensory neighborhoods changing rapidly (5, 7⇓–9). Yet nonetheless, individuals exhibit the capacity to change, consistently and repeatedly, the topology of their social connectivity by switching between what is often a relatively small number of group structural states (e.g., ref. 9). This presents an additional nuance to understanding collective cognition (10⇓–12), as while individuals may be influenced by the topology of their network, they are also able to modify this topology through their movements and perception of the environment.

Here we explore the possibility that information processing may be facilitated not only by individuals changing their internal behavioral rules/states, as is typically considered in animal behavior, but that, by forming a networked system, individuals can facilitate collective computation by changing the structural topology of the network (their social connectivity), without necessarily adjusting the way they respond to sensory information. We refer to changes in individual behavioral rules and states as individuals changing their responsiveness and to changes in group structure as individuals changing their spatial positioning.

Across many animal taxa, group structure is known to be highly sensitive to group members’ perceptions of risk and resources (13⇓⇓⇓⇓⇓–19). These changes have generally been attributed to simple game theoretic considerations (20, 21), where structure is merely a byproduct of individuals acting to maximize their survival (5). But overlooked is the possibility that group structure, as an emergent encoding of the external environment, could itself be an important mechanism by which organisms effectively process information in a changing world. In this way, the group’s structure could act as a collective memory that modifies future decisions, similar to how an individual’s memory guides its own behavior (22, 23).

To test the relative contributions of group members’ responsiveness vs. spatial positioning to collective information processing, here we present results from experiments with schooling fish (golden shiners, Notemigonus crysoleucas), known to have highly dynamic and self-regulating group structure (9, 16, 19), and use these data to investigate context-dependent changes in individual and collective responses to perceived risk. Like many fish species (3, 24, 25), predation is a source of extremely high mortality in the wild (26) and juveniles form coordinated schools in response to this risk. Shiners also exhibit startle responses as an escape behavior (27) that is socially contagious (28). Startles in this species occur even in the absence of an external stimulus, and these spontaneous false alarms propagate through the group in the same manner as triggered true alarms (28). In nature, false alarms account for a high proportion of overall alarms (29⇓⇓–32), very likely because there are such considerable costs to not responding to true threats relative to false alarms (33).

In our experiments, we manipulate the magnitude of perceived risk (individuals’ priors that an immediate threat is present) by introducing, remotely, the natural alarm substance Schreckstoff. Schreckstoff is a family of chondroitins released from fish skin when punctured or torn, such as in the vicinity of a successful predation event (34⇓⇓–37), that induces a “fear response” in fish, increasing group cohesion and startling behavior (37⇓–39). However, while response to Schreckstoff is innate (37), fish will habituate to Schreckstoff if repeatedly exposed with no paired stimulus (39⇓–41). As will be shown, these changes in group structure and collective responsiveness (the increased spread of alarms) allow us to ask whether this context-dependent change in collective behavior results from individuals modulating their responsiveness to neighbors and/or whether risk is encoded by changes in the groups’ internal spatial structure. Our analyses, involving automated tracking, computational visual field reconstruction, and determination of the functional mapping between socially generated sensory input and individual and collective response, allow us to not only distinguish between these alternative mechanisms, but also demonstrate the relative importance of each.

Conclusions The central question of our paper is whether collective sensitivity is modulated by changes in individuals’ responsiveness (rules for translating sensory input into alarms), their spatial positioning (the physical spacing and sensory network of group members), or some combination of them. In solitary animals, the only option for responding to changing environmental conditions is to modify responsiveness. For social animals such as golden shiners, either option (or a combination) is possible. Our approach allows us to separate the relative contributions of spatial positioning and individual responsiveness, and we find that any changes in collective responsiveness are predominantly encoded in spatial positioning. Using a combination of experiments and modeling, we demonstrate that individual-level changes in responsiveness do not contribute meaningfully to the augmented spread of startle cascades under perceived risk. Risk did not change the sensory features predictive of responding to neighboring alarms or the sensitivity to these features. Information on whether a startle occurred under baseline or alarmed conditions did not improve the ability to predict startle responses. In our behavioral contagion simulations where we explicitly vary individual responsiveness, we found that changes in responsiveness are not necessary to generate the observed changes in cascade sizes. Finally, when simulating cascades under solely changes in responsiveness, changes in spatial positioning, or both, we find that average cascades did not change with changes in responsiveness but did with changes in spatial positioning. In contrast to typical conceptualizations of collective cognition, in which individuals interact on a relatively fixed network structure (51, 52), the fish schools in our experiment can change their group structure on the same timescale as relevant changes in the environment. The fact that this group structure encodes relevant environmental features suggests that the fish could actively control and make adaptive use of their emergent group features, a concept with growing theoretical support (53⇓⇓⇓–57). The work we have presented here indicates the potential for self-organized animal groups to reveal additional insights into how dynamical networks may play an important role in collective intelligence emerging from simple interacting components.

Materials and Methods Experiments. Groups of 40 golden shiners were filmed freely swimming in a 1.06 × 1.98-m tank filled to 4.0 cm depth. One hour after being transferred to the tank, an automated sprayer released either Schreckstoff or water into the tank. The group was then filmed for an additional 0.5 h. No experimenter was present in the room for the duration of the trial. Details on data extraction, processing, and analysis are available in SI Appendix, section 1. All experiments were conducted in accordance with Princeton University’s Institutional Animal Care and Use Committee. Behavioral Contagion Model. Our model is based on a generalized model of contagion proposed by Dodds and Watts (50, 58). Here, we have reformulated the original model in terms of activation rates to describe behavioral contagion dynamics in continuous time. This allows us to more easily constrain parameters based on experimentally determined timescales and networks of influence, derived from the logistic regression’s predictions for response probabilities given fish positions at the time of the initial startle. We then simulate the model using a standard Euler discretization. Individual fish, as nodes in a network, are connected by weighted directed edges w i j ∈ [ 0,1 ] that define the rate of signaling doses received by individual i when individual j startles. Each individual i can be in 1 of 3 states s i that we call susceptible, active, and recovered. Susceptible nodes may become activated due to inputs received from active neighbors. After a fixed activation time τ a c t , activated individuals transition into the recovered state. The activation time is set to τ a c t = 0.5 s, matching the experimentally observed average startle duration. For simplicity, we consider the recovered state as an absorbing state with no outward transitions, which restricts the model dynamics to single, nonrecurrent cascades. A simulation run is terminated when no active individuals remain. As an initial condition we set all individuals as susceptible, and at time t = 0 a single individual is activated (spontaneous startle). A susceptible individual i receives from an active neighbor j stochastic doses of activating signal of size d a at a rate r i j = ρ max w i j , with ρ max being the maximal rate of sending activation doses for w i j = 1 . The maximal activation rate is bounded by limits on response times due to physiological constraints and neuronal processing of sensory cues which trigger a startling response in fish (59). The fastest startling responses to artificial stimuli were reported to be of the order of few milliseconds. Therefore, we assume ρ max = 1 0 3 s−1, which allows in our model for fastest response times of the order of 1 ms (for w i j ≈ 1 ). To be able to resolve this timescale, we choose the numerical time step accordingly to Δ t = 1 ms ( ρ max = 1 / Δ t ). Thus, with small Δ t , the activation signal received from individual j is a stochastic time series d i j ( t ) with 2 possible values, d a and 0, whereby the probability of receiving an activation dose per simulation time step Δ t is p a = r i j Δ t . Each agent integrates all inputs over a finite memory τ m = 2 s. The agent becomes activated if the cumulative dose D i ( t ) = 1 K i ∑ j ∫ t − τ m t d i j ( t ′ ) d t ′ [1]received by a susceptible agent i within its memory time exceeds its internal threshold θ i . Here, K i is the in degree of the focal individual, such that the doses received by the focal individual are rescaled by the number of its network neighbors, a form supported by prior work in a similar system (28). The individual thresholds are drawn from a uniform distribution with minimum 0 and maximum 2 θ ¯ , producing an average threshold of θ ¯ . This accounts for stochasticity due to inaccessible internal states of individuals at the time of initial startle. The expected value of the cumulative activation dose received by agent i due to the activation of a single neighbor j ( K i = 1 ) over the activation time τ a c t is thus ⟨ D i ⟩ = d a ρ max w i j τ a c t . We choose the weights w i j to be equal to the probability that i responds and is the first responder to an initial startle of j, inferred using the logistic regression model depicted in Fig. 3. The linear relationship between the cumulative dose ⟨ D i ⟩ and the weights w i j , along with the uniform distribution of thresholds across fish, guarantees that the complex contagion process produces the correct relative initial response probabilities in the limit of small Δ t and w i j (SI Appendix). Without loss of generality, we can set d a ρ max = 1 . Thus, based on the maximal rate ρ max = 1 0 3 s−1, we set the activation dose d a = 1 0 − 3 . This leaves us with a single free parameter, the average dose threshold θ ¯ , which we fit via maximum likelihood. A total of 1 0 4 independent runs were performed for each threshold value to estimate corresponding cascade size probability distributions.

Acknowledgments We thank the Couzin Laboratory for helpful discussions. This work was funded by an NSF Graduate Research Fellowship (to M.M.G.S.). C.R.T. was supported by a MindCORE (Center for Outreach, Research, and Education) Postdoctoral Fellowship. P.R. and W.P. were funded by the Deutsche Forschungsgemeinschaft (DFG) (German Research Foundation), Grant RO47766/2-1. P.R. acknowledges funding by the DFG under Germany’s Excellence Strategy–EXC 2002/1 “Science of Intelligence”–Project 390523135. I.D.C. acknowledges support from the NSF (IOS-1355061), the Office of Naval Research (N00014-09-1-1074 and N00014-14-1-0635), the Army Research Office (W911NG-11-1-0385 and W911NF14-1-0431), the Struktur- und Innovationsfunds für die Forschung of the State of Baden-Württemberg, the Max Planck Society, and the DFG Center of Excellence 2117 “Center for the Advanced Study of Collective Behavior” (ID: 422037984).

Footnotes Author contributions: M.M.G.S., J.B.-C., and I.D.C. designed research; M.M.G.S. performed research; C.R.T., W.P., B.C.D., and P.R. contributed new reagents/analytic tools; M.M.G.S. and W.P. analyzed data; M.M.G.S., C.R.T., J.B.-C., W.P., B.C.D., P.R., and I.D.C. wrote the paper; and C.R.T., J.B.-C., W.P., B.C.D., and P.R. developed the mathematical model and performed and analyzed numerical simulations.

The authors declare no conflict of interest.

This article is a PNAS Direct Submission.

This article contains supporting information online at www.pnas.org/lookup/suppl/doi:10.1073/pnas.1905585116/-/DCSupplemental.