Abstract
Fearful stimuli elicit a mix of active (e.g., evasion) and passive (e.g., freezing) behaviors in a wide range of species, including zebrafish (Danio rerio). How these different responses are encoded in the brain, and the extent to which individuals vary in their fear responses, is not clear. To investigate this, we first developed a contextual fear conditioning paradigm in adult zebrafish where fish associate a specific tank with an aversive pheromone, conspecific alarm substance (CAS). We collected data from over 300 fish across four different strains (AB, TU, TL, and WIK) and both sexes finding that, as expected, fish exhibit a mix of active and passive responses during CAS exposure and during memory expression. We also found that behavior fell into four distinct groups: non-reactive, evaders, evading freezers, and freezers, with the evading freezer and freezer groups most clearly associated with memory formation. Background strain and sex also influenced how fish respond to CAS, with males more likely to increase evasive behaviors in response to CAS and the TU strain more likely to be non-reactive during recall. Finally, using whole-brain activity mapping, we identified the brain regions associated with active and passive fear responses during memory expression and how the functional brain networks of evading freezers and freezers differed. Freezing behavior was associated with widespread neural activity that was particularly strong in the cerebellum, reticular formation, and parts of the telencephalon associated with olfactory processing. Evasive behavior was associated with an increase in the activity of visual threat detection and a decrease in the activity of brain regions related to foraging and navigation. Network analysis revealed that animals with high freezing and low evasion (i.e., freezers) had strong interactions between the pallium and cerebellum as well as strong interconnectivity between visual (pretectal) and thalamic analog (preglomerular) nuclei. Animals that mix freezing with evasive behaviors (i.e., evading freezers) had higher subpallial connectivity to regions involved in autonomic function and stress responses such as the hypothalamus and preoptic areas.
Introduction
Fear is an emotional state elicited by perceived threat. Behaviorally, fear manifests as stereotypical responses that have a striking similarity across a range of taxa (Adolphs, 2013; Darwin, 1872). These responses can be classified into two broad categories: active (e.g., fighting or fleeing) and passive (e.g., freezing or immobility) with the decision of the right behavior at the right time being critical to survival. For example, evasive behaviors may be ideal when a predator is actively striking whereas freezing (i.e., a lack of movement) may be best when a predator is lurking. Recalling where fearful stimuli have been experienced is key to avoiding predation, enabling animals to anticipate danger and optimize survival strategies (Mobbs et al., 2015). This place-fear learning, termed contextual fear conditioning, has been widely studied, however, the extent to which individuals categorically differ in fear expression and how such differences are represented in the brain, remains poorly understood despite being relevant to a variety of psychiatric disorders like PTSD and anxiety (Mancini et al., 2025; Maren et al., 2013; Ressler et al., 2022).
One of the most reliable and ethologically relevant elicitors of fear in animals are alarm pheromones. These are small molecules released by animals as a form of communication, signaling the presence of a threat (Tirindelli et al., 2009). The existence of alarm pheromones is well established in many species of insects, fish, and mammals (Verheggen et al., 2010) and is being increasingly recognized in humans (de Groot and Smeets, 2017). In fish, the first description of alarm pheromone was by Karl von Frisch (von Frisch, 1938) in minnows (Phoxinus laevis), where he described how an extract of epithelial cells resulted in fear-related behaviors like freezing and erratic swimming. Responses were also species specific; fish preferentially respond to conspecific alarm substance (CAS) while ignoring substances from heterospecifics. He also found that fish formed memories of where they previously experienced exposure to CAS, and that individuals sometimes varied in their behavioral responses. More recently, variability in responsiveness to CAS has been reported in a range of fish species (Pfeiffer, 1977) including zebrafish (Danio rerio) (Speedie and Gerlai, 2008; Suboski et al., 1990). These findings suggest the presence of consistent individual behavioral differences in fear reactivity, but they have not been systematically examined.
Given the ethological relevance of CAS as a stimulus, it holds considerable potential for use in understanding individual variation in associative fear learning in zebrafish. In fear conditioning, a conditioned stimulus (CS) is paired with an intrinsically aversive unconditioned stimulus (US). Later presentation of the CS alone results in a conditioned response that is a measure of the strength of the memory. The CS can be either a discrete cue, like a light or sound, or a diffuse stimulus, like a tank or context. CAS has been successfully used as a US in Pavlovian fear learning assays in zebrafish where it has been associated with lights, odors, and contexts (Baker and Wong, 2019; Hall and Suboski, 1995; Maximino et al., 2018; Ruhl et al., 2017). These data suggest that fear learning using CAS is a robust phenomenon in zebrafish, making it ideal for determining if individual animals vary in fear memory expression and identifying the corresponding neural substrates.
To identify the presence of individual differences in fear behavior, we collected data from over 300 adult zebrafish across four inbred strains and both sexes. To increase throughput, we automated behavioral data analysis by combining DeepLabCut (Mathis et al., 2018) with a random forest supervised machine learning model (James et al., 2013). We then used unsupervised machine learning to identify the presence of individual differences in fear memory associated behaviors. Lastly, to identify the neural substrates of fear memory and variation in its expression, we mapped the whole-brain activity of animals during fear memory recall.
Results
Automated behavioral identification
To assess contextual fear memory in zebrafish we designed a three-day behavioral paradigm (Figure 1A). On the first day, animals were given five minutes to acclimate to the conditioning tank. On the second day, animals were placed in the tank for 10 minutes. Baseline behavior was captured during the first five minutes (i.e., pre-exposure). CAS (derived from a mix of donors from all four strains and both sexes) or vehicle was then added to the tank for the last five minutes. On the third day, fish were placed back in the same tank in the absence of CAS to assess fear memory. To automate the identification of different swimming behaviors, we trained a DeepLabCut (Mathis et al., 2018) network to track three points on the fish: the head, trunk, and tail (Figure 1B). We then used the output from this tracking to train a random forest model to identify five different behaviors: straight swimming, normal turns, freezing, burst swimming, and erratic movements. We used 34 parameters derived from the tracking to capture the movement of the animals over time (Table S1-1). These features were calculated using a sliding window of 45 frames (750 ms) to capture the temporal dynamics of movement. Approximately 14,000 frames were labelled for each of five different behaviors, with a 80/20 split for training/testing. We optimized the number of trees and number of features per tree, finding that 2,000 trees and 10 variables per tree optimized the out of bag error rate (2.88%). The resulting model had at least 94% accuracy for each behavior (Figure 1C). Notably, most of the misclassifications occurred when distinguishing between straight swimming versus normal turns and burst swimming versus erratic movements. Because these labels capture the same behavioral concept, and to simplify the subsequent analysis, we use “normal swimming” to refer to either straight swimming or normal turns and “evasive behavior” to capture erratic movement or burst swimming.

Fear memory paradigm and automated behavioral assessment.
A) Adult zebrafish were trained in contextual fear conditioning over three days using CAS as the unconditioned stimulus. B) Automated behavioral assessment began with tracking using DeepLabCut, followed by feature extraction and then training of a random forest model for classification. C) Confusion matrix for the random forest model using a model trained on 80% of the data and tested on 20% of the data not used for training.
Contextual fear learning
Given prior reports of behavioral variation in response to CAS, we hypothesized that this variation may be due, in part, to the background strain and/or sex of the animals. When looking at how fish respond to CAS itself, we found that almost all strains and sexes had an increase in freezing compared to vehicle treated animals (Figure 2A, top), and all groups were elevated relative to pre-exposure (Figure 2B, top). The only exception to this was female TL fish, where the vehicle treated animals also increased their freezing behavior, likely as a response to the small disturbance that occurs upon the addition of vehicle to the tank. We analyzed evasive behaviors as percent of time active (i.e., not freezing) since many fish spend a large proportion of their time freezing. This gives us a better estimate of evasion that is less influenced by the more dominant freezing behavior. Evasive behaviors in response to CAS had more variation.

Behavioral responses during fear conditioning.
A) Percent freezing (above) and % evasive behavior as a proportion of active behavior (below). Data are means ± SEMs. *-P < 0.05, †-P<0.10 compared to vehicle treated fish via FDR corrected t-tests. B) Change (in comparison to pre-exposure) in percent freezing (above) and percent evasive behavior (below) during exposure to CAS (left) and during memory day (right). *-P < 0.05, compared to zero via FDR corrected one-sample t-tests. Boxplot center is the median, hinges are interquartile range, and whiskers are the hinge ± 1.5 times the interquartile range. C) Freezing (above) and evasive behavior as proportion of active behavior (below) over time during pre-exposure, exposure, and memory days. Lines are means and ribbons are 95% confidence intervals. Vehicle treated groups, n’s = 12; CAS treated groups, n’s = 40-42. Part C includes all the CAS-treated animals (N = 331).
Compared to vehicle treated animals, CAS treated males in two out of four strains increased evasive behavior (except WIKs and TUs that approached significance; Figure 2A, bottom), whereas there were no changes in females. Compared to pre-exposure, CAS resulted in an increase in evasive behaviors in all groups except male WIKs (Figure 2B, bottom).
We next asked whether fish formed a long-term associative memory between the tank and CAS. To test this, fish were placed back into the tank one day after CAS exposure with no CAS present (i.e., memory day). On memory day, there was elevated freezing compared to vehicle treated animals and relative to pre-exposure in nearly all strains and sexes, with the exception of female TU fish that did not differ from their vehicle treated counterparts and male WIKs and ABs that only approached significance (Figures 2A and 2B, top). As before, evasive behaviors were more variable on memory day. When compared to vehicle treated animals, evasive behavior was only elevated in female TUs (Figure 2A, bottom). Compared to pre-exposure, no strains/sexes had an increase in evasive behaviors (Figure 2B, bottom).
To better understand the dynamics of freezing and evasive behavior, we examined temporal profiles of the behavior during the different stages of the paradigm (Figure 2C). During pre-exposure, there was an initial increase in freezing behavior that quickly decreased to ∼20%.
Evasive behavior remained consistently low throughout the trial. During exposure, CAS-treated animals had an initial burst in evasive behavior that rapidly gave way to persistent freezing. On memory day, we saw an initial increase in freezing behavior in both vehicle and CAS-treated animals, but while the freezing in vehicle treated animals quickly declined, the freezing in CAS treated animals was higher and persisted for longer (Figure 2C). Evasive behavior during memory day was largely similar between vehicle and CAS-treated animals, with only a slight increase in CAS treated animals at the beginning of the trial.
Transitions between behavioral states
The aggregated data we have examined so far does not yield insight into how fish switch between behavioral states. To examine these state changes, we constructed transition matrices binning behavior into 750 ms bins that matched the sliding window used for behavioral identification (Figure 3). We found that at all stages, freezing is the most stable behavior (i.e., the behavior is most likely to follow itself), even during pre-exposure when it is a relatively small proportion of the overall behavior (Figure 3A). Amongst the normal swimming behaviors of straight swimming and normal turns, transitions are most likely between these states across all stages of behavior. A similar pattern is seen for evasive swimming (i.e., erratic movements and burst swimming); however, these behaviors are less likely to occur after normal swimming than normal swimming is to occur after evasive behavior. Overall, there are no large changes in the patterns of transitions across the different stages of the behavioral paradigm. These data suggest that exposure to CAS does not result in wholesale reorganization of behavior, but instead a change in how much of each behavior is selected.

Transitions between behavioral states.
A) Transition matrices capturing how often zebrafish change from the source to the destination state at different stages of the contextual fear memory behavioral paradigm. B) Transitions between source and destination states over time for normal, evasive, and freezing behavior. Error bars are 95% confidence intervals.
To capture more subtle behavioral changes, we examined state transitions in response to CAS and at memory day in more detail (Figure 3B). To increase clarity, we collapsed straight and normal turns into “normal swimming” and burst swimming and erratic movements into “evasive behavior”. Here, we see that during both CAS and vehicle treatment, there is a slight destabilization of normal behavior such that normal behavior becomes less likely following itself; instead, in the vehicle group normal behavior is more likely to be followed by evasive behavior, and in CAS treated animals, normal behavior is more likely to be followed by freezing (Figure 3B, top row). This increase in evasion in the vehicle group likely represents a response to the water disturbance that occurs when solution is added to the tank. We also see that CAS causes freezing behavior to become more stable (Figure 3B, right column): compared to pre-exposure, freezing is more likely to occur following normal, evasive, and freezing at both exposure and memory day. Evasive behavior increases in likelihood following itself during CAS treatment, with little to no change following normal or freezing behavior (Figure 3B, middle column). This suggests that CAS results in longer bouts of evasive behavior without increasing its likelihood of occurring. In contrast, the CAS-induced elevation in freezing behavior during exposure and memory appears to be due to an increase in both the duration and number of freezing bouts.
Individual differences in fear memory expression
Given the large amount of variation in behavioral responses to CAS, especially during memory day (Figure 2B), we hypothesized the presence of distinct fear memory behavioral types. To uncover these types, we applied Louvain clustering to a series of k-nearest neighbor networks and identified the k-value that yielded the most robust and best clustering (k = 74; Figure S4-1) (Rajput et al., 2022). Distances between nodes (i.e., individual fish) in the network were calculated using percent evasion, percent evasion of active swimming, and percent freezing. Percent evasion of active swimming was included because fish that exhibit high levels of freezing will necessarily be low on non-freezing behaviors. By calculating evasion as a percent of active (i.e., non-freezing) behavior, we better capture what fish choose to do when not freezing. From this analysis, we identified four behavioral clusters (Figure 4A). We named these clusters (Figure 4B): (1) “non-reactive”: fish low in evasion and freezing; (2) “evaders”: fish low in freezing and high in overall levels of evasive behavior; (3) “evading freezers”: fish high in freezing and evasive behaviors; (4) “freezers”: fish high in freezing and low in evasive behaviors.

Clustering of zebrafish behavior during fear memory recall.
A) Two-dimensional representation of the three-dimensional behavioral space using a uniform manifold approximation (UMAP). The outer circles delineate the clusters as defined using Louvain clustering applied to a k-nearest neighbor network (k = 74). Each point represents an individual fish (N=331). B) Behaviors associated with the identified clusters presented as z-scores. Box plots indicate median (center line), interquartile range (box ends) and ± 1.5 times the interquartile range (whiskers). C) Behaviors across time for the different clusters; ribbons indicate 95% confidence intervals. D) Percentage of animals falling into each behavioral cluster across strain and sex. Striped bars (P < 0.05) represent under/over representation using permutation tests with FDR corrections; n’s = 40-42 per strain and sex.
Temporal profiles of behavior also reveal distinct differences (Figure 4C). For example, both freezer groups overlapped in the percent freezing behavior over time but differ in their evasive behavior, where the evading freezers have both higher overall levels of evasion and a greater proportion of active behavior spent evading throughout the entire memory trial. Likewise, the temporal profile of freezing for the evaders and non-reactive fish are equally low, but the evaders slowly increase their evasive behaviors over time whereas non-reactive fish remain low in evasion throughout the trial.
Finally, we asked whether behavioral types are affected by the strain and/or sex of the fish (Figure 4D). We found that in AB and WIK fish there was neither over nor underrepresentation in any of the four behavioral types. In contrast, TU fish were overrepresented in the non-reactive group, and TL males were overrepresented in the evading freezer group. This suggests that TU fish may be a poor choice for studying CAS-induced fear learning.
Behavioral clusters over time
We next asked if behavior during exposure to CAS is predictive of behavior at memory day. To do this, we identified which cluster each fish fell into at each behavioral stage (Figure 5A). In the vehicle treated group, animals were largely identified as either non-reactive or evaders at all three time points. In CAS-treated fish, only 14% of animals belonged to one of the freezing groups at pre-exposure. During CAS exposure, this proportion increased to 66%. On memory day, 48% of CAS treated fish were in one of the two freezing groups, about equally split between evading freezers (28%) and freezers (20%). We also found that the behavioral cluster of the fish on exposure day roughly predicted behavior on memory day (Figure 5B, diagonal).

Transitions between behavioral states over time.
A) Alluvial plot indicating the number of fish in each cluster during pre-exposure, exposure, and memory day for animals exposed to vehicle (left) or CAS (right). B) Confusion matrix of animals falling into different clusters during exposure and memory day. Numbers indicate the quantity of animals falling into each group on exposure and memory days. Vehicle treated fish; N = 96; CAS treated: N = 331.
Most fish in the non-reactive and evader groups on memory day fell into the same category during exposure (54-56%) or transitioned between evaders and the non-reactive groups (29%). Evaders and non-reactive fish rarely transitioned to freezing groups on memory day (11-16%). In contrast, a substantial minority of animals in the freezing groups transitioned to non-freezing groups (30-41%) with the majority remaining in one of the high freezing clusters (58-69%).
Taken together, these data suggest that fish behavior is largely consistent between exposure and memory days, although there remains a sizable minority of fish that appear to forget and switch from freezing to non-freezing behaviors at memory day.
Brain-behavior covariation
To determine the brain regions underlying different behaviors, we performed whole-brain activity mapping followed by partial least squares (PLS) analysis. We chose the AB strain of fish because they showed approximately equal distribution of the different behavioral types (Figure 4D). For brain mapping, animals were euthanized 15 minutes after fear memory recall and processed for tissue clearing using iDISCO. Neural activity was captured using in situ hybridization chain reaction (HCR) against cfos mRNA. Brains were imaged using light-sheet microscopy and then registered to the adult zebrafish brain atlas (AZBA) (Kenney et al., 2021; Rajput et al., 2025). We used PLS analysis (Krishnan et al., 2011) to determine how brain activity covaries with behavior during fear memory recall (Figure 6). This approach uncovers latent vectors that capture the maximal covariance between neural and behavioral states. The first behavioral contrast identified was significant (P = 0.0090), capturing freezing in the positive direction and evasion/normal swimming in the negative (Figure 6A, left); the second contrast approached, but did not reach significance (P = 0.107; Figure 6A, right). However, because this second contrast uniquely captured evasive behavior, we analyzed it with the caveat that these findings are not as strongly supported as those for the first contrast.

Partial least squares (PLS) analysis to identify brain regions that covary with behavior.
A) Top two contrasts and related behavioral saliences identified from PLS analysis. B) Bootstrap ratios of brain saliences for the first contrast on a sagittal image of the adult zebrafish brain. Only bootstrap ratios of above 2.5 or below -2.5 are depicted. C) Coronal slices with same coloration as part B. D) Bootstrap ratios of brain saliences for the second contrast on a sagittal image. E) Coronal slices of bootstrap ratios correspond to the second contrast. Brain region abbreviations can be found in Table S6-1. N = 87.
To determine which brain regions consistently contributed to the first behavioral contrast, we calculated bootstrap ratios (BSRs, i.e., salience scores). BSRs capture a combination of the magnitude and stability of regional contributions to a contrast (McIntosh and Lobaugh, 2004).
For the first contrast (Figures 6B and C, S6-1A), we found numerous positive contributions [BSRs > 2.5; i.e., neural activity covaried with freezing. Although PLS is multivariate, we have provided example univariate relationships between cfos activity and behavioral contrasts to give an intuition as to what relationships are being captured (Figure S6-2)]. This activity pattern suggests that freezing behavior, despite the lack of movement, is not passive at the neural level but instead involves a coordinated brain-wide activity. The cerebellum in particular stands out with several regions with very high BSRs: the CC (cerebellar crest; BSR = 4.7), CCe-m (molecular layer of the corpus cerebelli; BSR = 4.0), MON (medial octavolateralis nucleus; BSR = 3.6), and LCa (caudal lobe of the cerebellum; BSR = 6.5). The MON is one of the primary sites of lateral line input to the brain (Valera et al., 2021; Wullimann and Grothe, 2013) and interacts with the rest of the cerebellum (Dohaku et al., 2019; Pose-Méndez et al., 2023). Thus, this data suggests that freezing involves constant monitoring for movement in the water, possibly to maintain posture and minimize drifting. Maintenance of freezing is likely driven by regions of the reticular formation, which projects to the spinal musculature (Chong and Drapeau, 2007; Huang et al., 2013), where we also see strong associations with contrast 1: the SRF (superior reticular formation; BSR = 5.0), IMRF (intermediate reticular formation; BSR = 4.0), and SRN (superior reticular nucleus; BSR = 3.4). Finally, several regions of the telencephalon positively covaried with contrast 1, such as the nuclei of the lateral olfactory tract (nLOTa: BSR = 3.8, nLOTp: BSR = 3.0), parts of the bed nucleus of the stria terminalis (BSTpd: BSR = 3.8, BSTa: BSR = 3.22), the central and lateral portions of the ventral telencephalon (Vc: BSR = 3.1; Vl: BSR = 3.2), and the posterior and central portions of the dorsal telencephalon (Dp: BSR = 3.0; Dc: BSR = 2.8). These regions are likely working to scan and evaluate external chemosensory threats. The nLOTs and Dp regions receive input from the olfactory bulbs (von Bartheld et al., 1984; Yáñez et al., 2022). These regions likely work in concert with the BSTs, which are a part of the extended amygdala, to assign valence to chemosensory stimuli (Porter and Mueller, 2020). The BSTs likely interact with the Vc, which is proposed to be a part of the central amygdala (Porter and Mueller, 2020), a region important for the expression of emotional learning like fear conditioning (Ciocchi et al., 2010; Wilensky et al., 2006). Finally, the Dc is thought to be homologous to mammalian iscortex (Mueller, 2022; Mueller et al., 2011), integrating input from other parts of the brain, including the telencephalon, while projecting to midbrain regions to organize brain-wide activity (Yáñez et al., 2022).
For the second contrast (Figures 6D, 6E and S6-1B), there were only two regions with positive BSRs, and thus covaried with evasive behavior: the nucleus isthmi (NI: BSR = 2.6) and the subcomissural organ (SC: BSR = 3.1). The NI is important for visual attention and modulating retinotectal input, particularly in response to looming stimuli that signal danger (Fernandes et al., 2021; Gruberg et al., 2006; Henriques et al., 2019). Thus, fish with more evasive behavior may be driven by greater attentiveness to potential visual threats. The SCO has recently been found to secrete glycoproteins that form Reissner fiber’s in the spinal cord that help detect spinal curvature (Cantaut-Belarif et al., 2018; Orts-Del’Immagine et al., 2020), and so this region may be more active in order to repair Reissner fibers that come under stress due to the rapid changes in spinal curvature that occur during evasive movements. Regions related to foraging behavior and mechanosensory feedback negatively covaried with contrast 2 and thus are more engaged during normal swimming. For example, with respect to foraging, we have negative BSRs for regions important for spatial navigation like the periventricular gray zone of the optic tectum (PGZ: BSR = -2.8) and the anterior thalamic nucleus (A: BSR = -2.5), which are involved in processing a wide range of visual information (Baier and Scott, 2024; Baier and Wullimann, 2021; Cheng et al., 2017) and the dorsal tegmental area (DTN: BSR = - 2.7), which is critical for monitoring head direction (Petrucco et al., 2023). The central nucleus of the inferior lobe (CIL: BSR = -3.0) is part of a region implicated in feeding behavior (Muto et al., 2017; Wee et al., 2019), but may also play a role in integrating sensory input (Bloch et al., 2019). Finally, several regions involved in sensory feedback are shut down during evasive behavior, likely in anticipation of the large inputs that would occur during evasive movements. These regions include those important for auditory processing in the nucleus of the lateral lemniscus (NLL: BSR = -3.1) and central nucleus of the semicircular torus (TSc: BSR = -3.0) (Yáñez et al., 2024), and vestibular information like the nucleus lateralis valvulae (NLV: BSR = - 3.6), and the caudal lobe of the cerebellum (LCa: BSR = -2.9) (Pose-Méndez et al., 2023).
Brain networks underlying individual differences in behavior
The brain is best thought of as a network of interacting regions whose complex interactions give rise to behavior. To determine the patterns of activity that are present during different types of fear memory expression, we generated networks from correlated cfos activity between brain regions for each experimental group (Figure 7). The overall pattern of correlations (Figures 7A & B) is similar in the groups exposed to the behavioral tank (i.e., non-reactive, evading freezer, and freezer groups; similarity of matrices: r’s=0.41-0.43) while clearly differing from the habituation group that was not exposed to the behavioral tank (r’s=0.18-0.24). To identify which regional interconnections were significant for network generation, we applied a threshold (FDR < 0.001; Figure 7C). This identified fewer significant correlations in the non-reactive group (306) than the evading freezer (588) and freezer groups (655), suggesting these latter two groups form a more coherent brain network.

Covariation between brain regions across behavioral groups.
A) Correlation matrices of cfos activity between brain regions. Each row/column is an individual brain region, and each entry is the Pearson correlation of cfos activity across animals in a group. Colored bars represent the ontological level of each brain region. B) Pearson’s correlations of matrices from each group with one another. Error bars are bootstrapped 95% confidence intervals. C) Correlation matrices with only suprathreshold correlations (FDR < 0.001). Habituation: n = 19; non-reactive, n = 17; evading freezer: n = 16; freezer: n = 21.
To generate insight into how the patterns of brain activity in the evading freezer and freezer groups differed, we generated functional networks (Figure 8). In these networks, the nodes represent brain regions and edges represent the presence of a suprathreshold correlation (Figure 7C). To better visualize how the networks in these two behavioral groups differed, we identified edges whose confidence intervals did not overlap with those of the other behavioral network or the non-reactive network (Figure 8A, solid lines). Significant edges/correlations that had overlapping confidence intervals are depicted as dashed lines.

Functional brain networks underlying fear memory expression.
A) Functional networks where nodes represent brain regions and edges the presence of suprathreshold correlations (FDR < 0.001). Node colors correspond to ontological levels from figure 7. Solid lines are edges whose 95% confidence intervals do not overlap with either of the other two networks (evading freezer, freezer, or non-reactive). Dashed lines represent edges that have 95% confidence intervals that overlap with one (dark gray) or both (light gray) of the other networks. B) Degree centrality of the top 15 nodes. Bars are colored according to the number of edges that arise from unique (light gray) or overlapping confidence interval (dark gray = 1 overlap or black = 2 overlaps). Overlaps defined the same as in part A. C) The relative degree score for nodes enriched in the evading freezer (positive) or freezer (negative) functional networks. Only those nodes with a relative degree score of more than ± 0.5 and degree greater than 12 are shown. Brain region abbreviations can be found in table S6-1.
All networks (freezer, evading freezer, non-reactive, and habituation; Figures 8A and S8-1, S8-2) have strong interconnectivity in the telencephalon (blue), including high degree centrality both the lateral zone of the dorsal telencephalon [Dl (degree: evading freezers = 30, freezers = 27, non-reactive = 25, and vehicle = 23)] and the medial zone [Dm (degree: evading freezers = 23, freezers = 27, non-reactive = 20, and vehicle = 27)]. These regions are notable for being the putative homologs to the mammalian hippocampus (Dl) basolateral amygdala (Dm) (Anneser et al., 2024; Ganz et al., 2012; Mueller et al., 2011; Porter and Mueller, 2020), both of which are well known to be critical for contextual fear conditioning in mammals (Tovote et al., 2015). This finding is particularly interesting because it suggests that these regions are activated somewhat non-specifically simply by being placed back into the conditioning tanks.
High inter-connectivity of these regions does not occur following an initial exposure to a novel tank (Rajput et al., 2025), and thus this pattern of activity may represent a general response to being placed back into a previously experienced context.
The evading freezer network is notable for its numerous interactions between the subpallium (ventral telencephalon) and hypothalamus (orange). In particular, there is high degree centrality in the mammalian homologs of the central and medial amygdala (Vd-vd, Vc, and Vp), striatum (Vd), and septum (Vv) (Porter and Mueller, 2020; Rink and Wullimann, 2004). Thus, in evading freezers it appears that the Vd-vd, Vc, and Vp may help evaluate the threat while vacillation between active and passive responses is likely regulated by the septal homolog (Vv; Besnard et al., 2019; Rizzi-Wise and Wang, 2021) with the evasive behavior program likely initiated by the striatal homolog (Vd). Notably, the Vv, is less engaged in the freezer network (degree = 9) where there is less switching between freezing and evasive behaviors. The Vv also has extensive projections to the preoptic area and hypothalamus (Rink and Wullimann, 2004; Rizzi-Wise and Wang, 2021), which contains several regions overrepresented in the evading freezer group [i.e., the dorsal and ventral hypothalamus (Hd and Hv) and the anterior and posterior preoptic areas (PPp and PPa)]. These preoptic and hypothalamic regions are key regulators of autonomic functions homologous to their mammalian counterparts (Biran et al., 2015). This suggests that the evading freezer behavioral type may be driven by an elevated stress response relative to freezers.
In contrast, the freezer functional network is notable for interactions between the telencephalon and the cerebellum, particularly the CC which has several unique connections with the dorsal telencephalon and has much higher degree than in the other two networks (degree: freezers = 25, evading freezers = 2, non-reactive = 0). The other notable aspect of the freezer network is the cluster that contains several unique connections between the pretectum and posterior tuberculum. Several parts of the posterior tuberculum stand out as being highly interconnected in freezers, like the medial and lateral preglomerular nuclei (PGm and PGl, respectively), and the posterior thalamic nucleus (P). These nuclei are thought to serve as key sensory processing regions for vision, gustation, and olfaction that then project to the pallium, not dissimilar in function to the mammalian thalamus (Bloch et al., 2020; Mueller, 2012; Northcutt, 2006). Thus, in freezers, enhanced sensitivity to sensory input may be modulating the pallium to signal to the cerebellum to control and maintain the freezing posture and suppress evasive behavior.
Discussion
The present study is the first to unambiguously identify the presence of individual differences in fear response and memory expression in zebrafish by building on prior work that found fish exhibit a mix of active and passive responses to CAS (Hall and Suboski, 1995; Maximino et al., 2018; Speedie and Gerlai, 2008; von Frisch, 1938). We can now add that individuals express fear memories in different ways: some individuals have high levels of freezing interspersed with normal swimming whereas others intersperse freezing with evasive behavior. Finally, we uncovered patterns of brain activity that differentiate these behavioral types, finding that engagement of some regions in the telencephalon are common across behavioral types, but differentiated by regions like the cerebellum, preglomerular nuclei, preoptic area, hypothalamus, and pretectum.
We found that fish respond to CAS with an increase in both freezing and evasive behaviors, with freezing being the more robust and persistent response that is less influenced by strain and sex. These responses to CAS itself are consistent with previous reports of active and passive responses in fish (Hall and Suboski, 1995; Maximino et al., 2018; Speedie and Gerlai, 2008; von Frisch, 1938). We also found that strain had a modest effect on behavior, with the most prominent finding being that TU fish were overrepresented in the non-reactive cluster during fear memory expression. This echoes prior work where the TU strain was found to have a faster rate of contextual fear memory extinction than the AB and TL strains (Kenney et al., 2017). This could potentially be due to a reduction in learning as the TU fish did not increase their freezing response to CAS as much as the other strains (Figure 2A). We also saw a sex difference with respect to evasive behaviors, where males are more likely to increase their evasive behaviors than females when CAS is present. Freezing, however, is largely similar across sexes. This is consistent with a recent study that found both male and female fish increase freezing in response to CAS (Akinrinade et al., 2023). However, the prior study found no increase in evasive behaviors in response to CAS, and no sex differences. We suspect that this may be because in the present study we assessed evasive behavior as a percentage of time not freezing whereas Akinrinade et al (2023) examined levels of evasive behavior as a proportion of total time. We took our approach because many fish spend more than half the time freezing in response to CAS, and so the opportunity for other behaviors is limited. By examining evasive behavior as the percentage of time spent not freezing (i.e., active time), we likely have greater sensitivity to uncover subtle behavioral differences.
A key finding from the present study was the identification of individual differences in how fish behave during fear memory recall. We found that fish behavior falls into one of four groups: non-reactive, evaders, evading freezers, and freezers. The evading freezer and freezer groups are the most clearly associated with fear memory. This is due to the substantial number of animals that fell into the evader category in the vehicle treated fish and the CAS treated fish during pre-exposure (Figure 5A). This suggests that an increase in evasion in the absence of freezing may be a behavioral response to netting and placement in the tank rather than to the alarm substance (Shishis et al., 2023). We suspect this elevated evasive behavior may also be due to the small size of the tank used in this study, which we chose to limit the amount of CAS needed to elicit a fear response.
Our findings on individual differences in fear memory expression are distinct from prior work examining such differences in rodents and fish that classify animals as being either high or low in fear expression. For example, using an active avoidance paradigm with CAS, Maximino and colleagues (2018) classified zebrafish as high or low in avoidance during memory expression, finding that high avoiders had higher levels of freezing and lower levels of erratic movements during CAS exposure. A similar approach has been taken in rats, where individual differences have been identified by differentiating animals based solely on their freezing responses to conditioned stimuli (Graham and Richardson, 2016; Walters et al., 2016).
Interestingly, rats have been found to exhibit a mix of active (darting) and passive (freezing) fear behaviors during fear conditioning to an electric shock where females exhibit more darting than males (Gruene et al., 2015; Mitchell et al., 2022). Elevated darting was also associated with less freezing in rats. These findings mirror some of the findings in the present study, such as the presence of both active (evasive) and passive (freezing) fear behaviors. However, we do not find as clear of a sex difference in active and passive behaviors during fear memory expression, and we find that an increase in evasive behavior does not necessarily lead to less freezing. These differences may be due to the use of a different unconditioned stimulus (CAS versus electric shock) and/or species.
We find that the cerebellum stands out as being strongly associated with freezing behavior. This conclusion is supported by both the PLS and network analysis. PLS analysis found that neural activity of several cerebellar regions (CC, CCe-m, LCa, and MON) strongly contributed to the covariation of brain activity with freezing behavior. The network analysis also identified the CC as a hub with many unique interactions with the pallium and subpallium.
Relatedly, the inferior olive (IO) was also identified as important by the PLS and network analysis. The IO is a key source of instructive input to the Purkinje cells of the cerebellum that process information and serve as its primary output (De Zeeuw et al., 1998; Dohaku et al., 2019; Pose-Méndez et al., 2023). A role for the cerebellum in fear-induced freezing is consistent with prior work in goldfish (Yoshida et al., 2004), and recent views of the cerebellum playing an important role in socio-emotional behavior alongside its more well established involvement in motor coordination (Strata, 2015). In looking closer at the functional connectivity of the cerebellum in freezers, we find connections between the CC, IO, and Dm where the Dm is thought to be the teleostan homolog of the basolateral amygdala (Mueller, 2022; Porter and Mueller, 2020) which has been implicated in fear memory learning in both zebrafish and rodents (Fanselow and LeDoux, 1999; Lal et al., 2018; Sun et al., 2020).
Another collection of brain regions that stands out as key to freezing behavior are the posterior tuberculum and pretectum. Within the posterior tuberculum, the preglomerular nuclei are amongst the top contributors to freezing in the PLS and network analysis (particularly the PGm which is supported by both sets of analyses). Preglomerular nuclei receive a variety of sensory inputs and project to the pallium, making it functionally analogous to the mammalian dorsal thalamus (Mueller, 2012; Wullimann, 2020). In particular, the PGm in goldfish, a related teleost species, receives chemosensory input (Northcutt, 2006). Thus, the PGm may work together with other chemosensory regions to recall the CAS memory, like the nLOTa, nLOTp, and Dp that positively co-vary with freezing behavior. Pretectal nuclei, like the PSp and PPv, were also identified as important by both the PLS and network analysis. The pretectum is key to visual processing as these regions receive retinal input and have reciprocal interactions with the optic tectum (Yáñez et al., 2018). Interestingly, several pretectal nuclei, including the PPv, receive or send projections to the CC of the cerebellum (Yáñez et al., 2018). Taken together, these data suggest that the freezing behavior in the absence of elevated evasive behavior, may be driven by a bias towards generating memories from combined visual and chemosensory inputs. These sensory memories then engage a cerebellar-telencephalic circuit to initiate the coordination of freezing behavior. However, further anatomical and functional manipulations would be required to more directly draw these conclusions.
In the functional brain network of evading freezers, we see greater engagement of the hypothalamus and preoptic areas than in freezers. For example, the network analysis identified the SC, PPp, and PPa, parts of the preoptic area, as high in degree and for having a higher proportion of unique edges than other brain regions. These regions formed a cluster that has many edges to hypothalamic and subpallial regions (Figure 8A). The preoptic area of zebrafish has been found to be a neurosecretory area, roughly homologous to the paraventricular nucleus in mammals (Herget et al., 2014). This region, along with other hypothalamic nuclei, modulate a broad spectrum of behaviors and physiological processes, including the hypothalamic-pituitary-interrenal (HPI) axis that regulates the release of cortisol, a central stress hormone (Biran et al., 2015; Wendelaar Bonga, 1997). Relatedly, CAS has been found to increase cortisol in zebrafish (Abreu et al., 2017); and in the frillfin goby (Bathygobius soporator) cortisol modulates the behavioral effect of CAS (Barreto et al., 2014). Thus, it may be the case that individual variation in the status of the HPI axis in zebrafish may determine if zebrafish exhibit a combination of evasive and freezing behaviors (i.e., evading freezers) or freezing interspersed with normal swimming (i.e., freezers).
In conclusion, we have identified the presence of individual behavioral variation in how zebrafish express fear memories. We find that the strain and sex of fish affect fear responses and that the behavioral response during learning is predictive of memory expression. Behavioral variation is associated with differences in the activity of brain regions like the cerebellum, preglomerular nuclei, preoptic area and hypothalamus. Future work will be needed to probe the function of these circuits and determine how they may be differentially wired to give rise to variation in behavior.
Materials and Methods
Subjects
Animals were female and male zebrafish from the AB, TU, TL and WIK strains 6 to 9 months of age. Fish were bred in-house and raised at Wayne State University and were within two generations of fish obtained from the Zebrafish International Resource Center (ZIRC - University of Oregon). Fish were housed in a re-circulating system (Aquarius Fish System, Aquatic Enterprises) with a 14/10-hour light/dark cycle (lights on at 8:00 a.m.; pH 7.5 ± 0.2 °C; water conductivity 500 ± 10 μS; temperature 27.5 ± 0.5 C). Fish were fed two times a day with dry feed in the morning (Gemma 300, Skretting) and brine shrimp in the afternoon (Artemia salina; Brine Shrimp Direct). All the procedures were approved by the Wayne State University Institutional Animal Care and Use Committee (Protocol ID: 21-02-3238).
For the behavioral experiments, animals were housed in male/female pairs (2 female/male pairs per tank separated by a transparent divider) in a 2L tank for one week before behavioral manipulations. The pair-housing system minimizes potential stress induced by social isolation (Parker et al., 2012), and maintains a consistent environment while allowing for the identification of individual fish across days. Behavioral experiments were performed between 11:00 and 15:00 h. Fish were moved to the behavioral room 1 hour before experiments to allow animals to adapt to the new environment. The fear conditioning task consisted of 3 days of behavioral testing: day 1: habituation; day 2: conditioning; day 3: memory recall (Figure 1A).
After behavioral recording, animals remained in the room for 1 hour before being moved back to the re-circulating system. Sex was determined using three secondary sex characteristics: body shape, color, and presence of tubercles on the pectoral fins (McMillan et al., 2015). At the end of the experiment, we confirmed sex after euthanization by dissection to identify the presence of eggs. To ensure data reliability, eight independent batches of offspring for each strain were used for behavioral testing (n = 12 – 16 per strain in each batch). All behavioral testing was carried out using a counterbalanced design across sex and placement in tank (front/back).
Fear conditioning
The fear conditioning protocol was adapted from prior work (Kenney et al., 2017) to use the Zantiks automated system (Zantiks Ltd) and conspecific alarm substance (CAS) as the unconditioned stimulus (Maximino et al., 2018). Two tanks (20 x 7 x 9 cm) were recorded simultaneously during the experiments at 60 fps. A pilot study was performed to determine the best CAS concentration starting with previous work in which a concentration of 3.5mL/L elicited fear-related responses up to 7 days after exposure (Maximino et al., 2018). We found a 1:10 dilution of this dosage (0.35 mL/L) elicited a robust freezing response with some variation on memory day (Figure S2-1). Fish were tracked using DeepLabCut (Mathis et al., 2018) by labelling three points (head, trunk and tail). We used ResNet101 network and trained a deep neural network on 200 manually labelled frames (divided across the four strains and both sexes), the network was then refined and improved by correcting outliers to include 578 additional frames.
CAS extraction
CAS is a substance released by fish when their epithelial cells are damaged, typically in response to a strike from a predator. We extracted CAS as previously described (Egan et al., 2009; Quadros et al., 2016). Briefly, CAS was obtained from donor fish that were euthanized via rapid cooling in 4 °C water. Fish were placed in a 10 cm petri dish and epidermal cells were damaged via 10 shallow incisions on both sides of the body using a surgical blade on ice without drawing blood. 10 mL of distilled water was then added to the dish and it was gently agitated to ensure complete coverage of the lacerated areas on the fish body. Because 4 different strains were used for the behavioral experiments, we prepared stock solutions of alarm substance by mixing extract from 1 fish per sex/strain and then aliquoting before storing at -20 °C for no longer than 4 weeks.
Behavioral analysis
To automate capture of behavior we developed a random forest machine learning model. After fish were tracked using DeepLabCut, we calculated postural information for each individual, extracting 34 parameters (Table S1-1) over a sliding window of 750 ms (45 frames). We manually labelled 14,199 frames per behavior for training the following behaviors: (1) freezing, the absence of movement with fast opercular movements, (2) erratic movements, zig-zagging movement of at least 3 quick C-bends, (3) burst swimming, a rapid increase of speed in one direction, 4) straight swimming, normal speed swimming in one direction and, (5) normal turns, (Figure 1B). We used an 80/20 (train/test) split for training and testing the model.
Optimization of the model was done by testing a range of variables per level (1-15) and trees. We found that 10 variables and 2,000 trees yielded the lowest out of bag error rate (2.88%). Results of testing on 20% of unseen data also yielded excellent results with errors of no more than 6% and typically much lower (Figure 1C).
To analyze the temporal organization of zebrafish behavior, we modeled behavioral state transitions using discrete-time Markov chains. Behavioral sequences were determined by calculating the modal behavior in 750 ms time windows. This time window matched the length of the sliding window used in the random forest classifier. Transition matrices were calculated using maximum likelihood estimation using the markovchain package in R (Spedicato, 2017).
Matrices were fit using data pooled across all animals within each experimental group and day. Ninety-five percent confidence intervals were computed and used for determining significance.
Identification of behavioral clusters
Clusters were identified by creating a k-nearest neighbor network and then applying the Louvain community detection algorithm (Blondel et al., 2008). We only used behavior on memory day from fish exposed to CAS. To calculate distances for the k-nearest neighbor network, we first standardized the behavioral data (% freezing, % evasion, and % evasion as a proportion of active time). We then calculated similarity scores between individual fish:

where D is the Euclidean distance between each fish in three-dimensional behavioral space. We selected the optimal k value by calculating internal clustering metrics using the clusterCrit package (version 1.3.0) at each value of k: Calinski–Harabsz index (Caliński and Harabasz, 1974), silhouette index (Rousseeuw, 1987), and Davies–Bouldin index (Davies and Bouldin, 1979). Based on these data, we chose k = 74, which fell within a range that optimized internal clustering metrics and showed robustness to small changes in k (Figure S4-1). Clustered data were visualized using a uniform manifold approximation (UMAP) (McInnes et al., 2020) as implemented in the UMAP R package (version 0.2.10).
To identify clusters in new data, such as during pre-exposure and exposure or in fish used for brain imaging analysis, we first standardized the new data using the parameters from the initial clustering described above. We then assigned clusters to each fish based on the number of connections to its 33 nearest neighbors in the initial network. Thirty-three was chosen because it is half the size of the smallest cluster identified.
Tissue clearing and staining
Brains were collected 15 min after the end of fear memory expression. Fish were rapidly euthanized via submersion in ice cold water and heads were removed and fixed in 4% paraformaldehyde (PFA) overnight. Animals that were assigned the wrong sex (determined post-mortem as described above) were removed from data analysis, as well as its paired fish (< 2%). After overnight fixation, brains were carefully dissected in cold PBS. Brains damaged during the dissections were discarded. Tissue staining and clearing was performed using iDISCO+ (Renier et al., 2016) as previously described (Rajput et al., 2025). After dissections, samples were washed three times with PBS (30 min washes) at room temperature followed by dehydration using methanol/water (20, 40, 60, 80 and 100% methanol for 30 min each).
Samples were placed in 100% methanol for one hour and chilled in the fridge (4° C). They were then incubated at 4° C overnight in 5% hydrogen peroxide in methanol. The next day, samples were rehydrated in methanol/water (80, 60, 40 and 20%, 30 min each) followed by two PBS washes, one PTx.2 (PBS with 0.2% TritonX-100) of one hour each and an overnight incubation in 5xSSCT buffer (sodium chloride sodium citrate and 0.2% TritonX-100). The following day, an acetylation step was performed with 0.25% v/v acetic anhydride for 30 min followed by three washes with ultrapure water for 5 min each. Samples were then incubated in hybridization buffer (Molecular Instruments) for 15 min at room temperature followed by one hour incubation at 37° C with the same buffer. A solution of hybridization buffer and cfos probes (2 pmol per sample) was then prepared and samples were incubated with the probes for 3 days. Samples were then washed three times using probe wash buffer (Molecular Instruments) followed by two 5xSSCT washes of one hour each. Finally, samples were incubated for 1 h with amplification buffer (5×SSC, 0.1% Tween 20, 10% dextran sulfate) and then incubated in the dark for 3 days in 125 µL of amplification buffer and 2.5 µL of each B1 hairpin (7.5 pmol). After amplification, samples were kept in the dark and washed five times in 5xSSCT buffer and left overnight. Clearing then began with dehydration in methanol/water mixtures (20, 40, 60, 80, 100, and 100%) for one hour each, followed by three hours incubation in dichloromethane/methanol (66%/33%) solution. Samples were then incubated two times for 15 min with dichloromethane. Lastly, the solution from the tubes was removed and dibenzyl ether was added to the samples in which they remained until imaging.
Whole-brain imaging
Cleared samples were imaged via light-sheet microscopy on an UltraMicroscope II (Miltenyi Biotec). Samples were immersed in dibenzyl ether and affixed to a pedestal using a refractive index matched ultraviolet cured resin (NOA 61, Norland Products). Images were acquired at 5× magnification. Illumination of samples was from the right laser using dynamic horizontal focusing and a step size of 4 µm. Autofluorescence images were acquired using a 480 nm laser and used for registration. Cfos images were acquired using an illumination laser of 641 nm. The exposure time was 200 ms, sheet width of 50%, and a sheet numerical aperture of 0.156. Images were acquired as 1 × 2 tiles and stitched using TeraStitcher (Bria and Iannello, 2012).
Automated cell detection
Detection of cfos positive cells was done using CellFinder, version 0.4.20 (Tyson et al., 2021) as previously described (Rajput et al., 2025). Briefly, cell candidate detection was first performed and those cell candidates that were closer than 9 µm to one another were removed. We then applied the CellFinder artificial neural net supervised machine learning algorithm to differentiate cells from non-cells. To train the CellFinder network, we labelled 25,460 cells and non-cells and trained the network to an accuracy of 97.7%. For one brain, cell counting was unsuccessful in the telencephalon and so these regions were excluded from the analysis.
Registration to AZBA
Images were registered to the adult zebrafish brain atlas (AZBA) using advanced normalization tools (version 2.4.4; Avants et al., 2011) to automatically parcellate brains into individual brain regions as previously described (Rajput et al., 2025). We initially generated a template from autofluorescence images that was a combination of a previously generated template (Rajput et al., 2025) and 10 brains from the present study. The autofluorescence image from AZBA was then registered to the template and the transformation from each individual brain to the template was used to bring the AZBA autofluorescence image into the space of individual brains. We had poor registration of the olfactory bulbs in three brains and so these regions were excluded from the analysis for these samples.
Partial least squares (PLS) analysis
We implemented PLS analysis (Krishnan et al., 2011) in R to identify covariation between behavior and regional brain activity. Because of batch-to-batch variation in the brightness of cfos images, cell counts were normalized based on the median overall cfos count for each cohort. This normalized data was then used for PLS (n = 87). Only fish exposed to CAS during training day were included in the analysis. Using mean-centered behavioral PLS correlation, we applied a singular value decomposition to a matrix of correlations between normalized cfos counts and four behaviors: % normal swimming, % freezing, % evasive swimming, and % evasive swimming while active (i.e., not freezing). Because the behavioral data is measured as percentages, some of which were skewed, we used an arcsine square root transformation prior to the PLS analysis:

To determine which latent variables to consider, we applied permutation tests (resampled 10,000 times without replacement) and used this to calculate p-values associated with each singular value. To determine the reliability of brain region contributions to a specific latent variable, we used bootstrapping (resampled 10,000 times with replacement). Bootstrap ratios were calculated by dividing the salience associated with each brain region by its standard error calculated from bootstrapping. Bootstrap ratios are similar to z-scores and thus we consider a threshold of ± 2.5 as significant, which is roughly equivalent to a two-tailed p-value of 0.01.
Brain network analysis
Brain networks were derived from Pearson correlation matrices capturing covariation between cfos counts per brain region across animals in each experimental group. Matrices were thresholded using a false discover rate (FDR) ≤ 0.001 (Benjamini and Hochberg, 1995). For calculating the initial p-values from Pearson’s correlations, we used the lowest number of observations (n = 16) from the groups used for making networks. We made this conservative correction because the p-value is highly sensitive to the number of observations, which would cause a large skew in the number of significant edges identified for each group. To capture edges that were unique to each network, we identified edges whose 95% confidence intervals did not overlap between networks. Only those edges that were significant (i.e., FDR ≤ 0.001) and did not have overlapping confidence intervals (CI) were labelled as ‘unique’. Those with only one overlap were labelled as ‘1 overlapping CI’.
Clustering of graphs was done by identifying the partition that maximized modularity. Relative degree scores for evading freezer and freezer networks were calculated using the following equation:

Where Di,Fr and Di,EF are the degree of the ith node for the freezer and evading freezer groups, respectively. Networks were visualized using Cytoscape version 3.10.2 (Shannon et al., 2003; Su et al., 2014).
Coding and statistics
Analysis was performed using R version 4.3.3. To identify differences at specific time points during behavior we FDR (Benjamini and Hochberg, 1995) corrected independent samples t-tests and compared CAS and vehicle treated groups. One sample t-tests were used to compare difference scores to zero with p-values also corrected using the FDR. The markovchain package (version 0.9.5) was used to create the Markov chains for generating transition matrices to identify behavioral transitions (Spedicato, 2017). Missing values for brain activity were imputed via nuclear-norm regularized singular value decomposition as implemented in the softImpute package (version 1.4.3; Hastie et al., 2015; Mazumder et al., 2010). The regularization penalty (λ = 25) was determined empirically by identifying the inflection point in the scree plot of the singular values. Permutation resampling without replacement (10,000 times) was used to assess significance of strain and sex for each behavioral cluster. We used the igraph (Csardi and Nepusz, 2006; version 2.02) package for network analysis and the cccd (version 1.6) package to build the k-nearest neighbor networks.
Data availability
All data needed to evaluate the conclusion in the paper are present in the paper and the supplemental material. Supplemental files are available at Dryad: https://doi.org/10.5061/dryad.sqv9s4nfh:
File S01. Statistics for Figure 2A.
File S02. Statistics for Figure 2B.
File S03. Behavioral data for Figure 2.
File S04. Neural cfos and behavioral data for Figure 6.
File S05. Bootstrap ratios for Figure 6.
File S06. Neural cfos data for network generation for Figure 7.
File S07. Correlations and confidence intervals for freezer, evading freezer, and non-reactive networks.
File S08. Graphml file for evading freezer network in Figure 8A.
File S09. Graphml file for freezer network in Figure 8A.
File S10. Graphml file for non-reactive network in Figure S8-1.
File S11. Graphml file for vehicle network in Figure S8-2.
File S12. Cytoscape file containing all four networks (evading freezer, freezer, non-reactive, and vehicle).
Acknowledgements
We thank Ian Lee for copy editing of the manuscript.
Additional information
Funding
Funding was provided by the National Institute of General Medical Sciences (R35GM142566, JWK).
Author contributions
Conceptualization: BDF and JWK; Methodology: BDF, JH, and JWK; Investigation: BDF, JH, NR, DK and DL; Formal analysis: BDF, NR and JWK; Writing: BDF and JWK.
Funding
HHS | NIH | National Institute of General Medical Sciences (NIGMS) (R35GM142566)
Justin W Kenney
Additional files
References
- Divergent effect of fluoxetine on the response to physical or chemical stressors in zebrafishPeerJ 5:e3330https://doi.org/10.7717/peerj.3330PubMedGoogle Scholar
- The Biology of FearCurrent Biology 23:R79https://doi.org/10.1016/j.cub.2012.11.055PubMedGoogle Scholar
- Sex differences in social buffering and social contagion of alarm responses in zebrafishAnimal Cognition 26:1307–1318https://doi.org/10.1007/s10071-023-01779-wPubMedGoogle Scholar
- Molecular organization of neuronal cell types and neuromodulatory systems in the zebrafish telencephalonCurrent Biology 34:298–312https://doi.org/10.1016/j.cub.2023.12.003PubMedGoogle Scholar
- A reproducible evaluation of ANTs similarity metric performance in brain image registrationNeuroImage 54:2033–2044https://doi.org/10.1016/j.neuroimage.2010.09.025PubMedGoogle Scholar
- The Visual Systems of ZebrafishAnnual Review of Neuroscience 47:255–276https://doi.org/10.1146/annurev-neuro-111020-104854PubMedGoogle Scholar
- Anatomy and function of retinorecipient arborization fields in zebrafishJournal of Comparative Neurology 529:3454–3476https://doi.org/10.1002/cne.25204PubMedGoogle Scholar
- Contextual fear learning and memory differ between stress coping styles in zebrafishScientific Reports 9:9935https://doi.org/10.1038/s41598-019-46319-0PubMedGoogle Scholar
- Cortisol influences the antipredator behavior induced by chemical alarm cues in the Frillfin gobyHormones and Behavior 65:394–400https://doi.org/10.1016/j.yhbeh.2014.03.007PubMedGoogle Scholar
- Controlling the False Discovery Rate: A Practical and Powerful Approach to Multiple TestingJournal of the Royal Statistical Society: Series B (Methodological) 57:289–300https://doi.org/10.1111/j.2517-6161.1995.tb02031.xGoogle Scholar
- Dorsolateral septum somatostatin interneurons gate mobility to calibrate context-specific behavioral fear responsesNature Neuroscience 22:436–446https://doi.org/10.1038/s41593-018-0330-yPubMedGoogle Scholar
- Role of developmental factors in hypothalamic functionFrontiers in Neuroanatomy 9https://doi.org/10.3389/fnana.2015.00047PubMedGoogle Scholar
- Non-thalamic origin of zebrafish sensory nuclei implies convergent evolution of visual pathways in amniotes and teleostseLife 9:e54945https://doi.org/10.7554/eLife.54945PubMedGoogle Scholar
- Mesencephalic origin of the inferior lobe in zebrafishBMC Biology 17:22https://doi.org/10.1186/s12915-019-0631-yPubMedGoogle Scholar
- Fast unfolding of communities in large networksJournal of statistical mechanics: theory and experiment 2008:P10008https://doi.org/10.1088/1742-5468/2008/10/p10008Google Scholar
- TeraStitcher - A tool for fast automatic 3D-stitching of teravoxel-sized microscopy imagesBMC Bioinformatics 13:316https://doi.org/10.1186/1471-2105-13-316PubMedGoogle Scholar
- A dendrite method for cluster analysisCommunications in Statistics-theory and Methods 3:1–27https://doi.org/10.1080/03610927408827101Google Scholar
- The Reissner Fiber in the Cerebrospinal Fluid Controls Morphogenesis of the Body AxisCurrent Biology 28:2479–2486https://doi.org/10.1016/j.cub.2018.05.079PubMedGoogle Scholar
- Characterization of a thalamic nucleus mediating habenula responses to changes in ambient illuminationBMC Biology 15:104https://doi.org/10.1186/s12915-017-0431-1PubMedGoogle Scholar
- Interaction between hindbrain and spinal networks during the development of locomotion in zebrafishDevelopmental Neurobiology 67:933–947https://doi.org/10.1002/dneu.20398PubMedGoogle Scholar
- Encoding of conditioned fear in central amygdala inhibitory circuitsNature 468:277–282https://doi.org/10.1038/nature09559PubMedGoogle Scholar
- The igraph software package for complex network researchInterJournal, Complex Systems 1695:1–9Google Scholar
- The Expression of the Emotions in Man and AnimalsCambridge University Press Google Scholar
- A cluster separation measureIEEE transactions on pattern analysis and machine intelligence :224–227https://doi.org/10.1109/tpami.1979.4766909PubMedGoogle Scholar
- Human Fear Chemosignaling: Evidence from a Meta-AnalysisChemical Senses 42:663–673https://doi.org/10.1093/chemse/bjx049PubMedGoogle Scholar
- Microcircuitry and function of the inferior oliveTrends in Neurosciences 21:391–400https://doi.org/10.1016/s0166-2236(98)01310-1PubMedGoogle Scholar
- Tracing of Afferent Connections in the Zebrafish Cerebellum Using Recombinant Rabies VirusFrontiers in Neural Circuits 13https://doi.org/10.3389/fncir.2019.00030PubMedGoogle Scholar
- Understanding behavioral and physiological phenotypes of stress and anxiety in zebrafishBehavioural Brain Research 205:38–44https://doi.org/10.1016/j.bbr.2009.06.022PubMedGoogle Scholar
- Why We Think Plasticity Underlying Pavlovian Fear Conditioning Occurs in the Basolateral AmygdalaNeuron 23:229–232https://doi.org/10.1016/s0896-6273(00)80775-8PubMedGoogle Scholar
- Neural circuitry for stimulus selection in the zebrafish visual systemNeuron 109:805–822https://doi.org/10.1016/j.neuron.2020.12.002PubMedGoogle Scholar
- Subdivisions of the adult zebrafish subpallium by molecular marker analysisJournal of Comparative Neurology 520:633–655https://doi.org/10.1002/cne.22757PubMedGoogle Scholar
- Individual differences in the expression of conditioned fear are associated with endogenous fibroblast growth factor 2Learning & memory https://doi.org/10.1101/lm.039644.115PubMedGoogle Scholar
- Influencing and Interpreting Visual Input: The Role of a Visual Feedback SystemThe Journal of Neuroscience 26:10368–10371https://doi.org/10.1523/JNEUROSCI.3288-06.2006PubMedGoogle Scholar
- Sexually divergent expression of active and passive conditioned fear responses in ratseLife 4:e11352https://doi.org/10.7554/eLife.11352PubMedGoogle Scholar
- Visual and olfactory stimuli in learned release of alarm reactions by zebra danio fish (brachydanio rerio)Neurobiology of Learning and Memory 63:229–240https://doi.org/10.1006/nlme.1995.1027PubMedGoogle Scholar
- Matrix completion and low-rank SVD via fast alternating least squaresThe Journal of Machine Learning Research 16:3367–3402PubMedGoogle Scholar
- Nucleus Isthmi Is Required to Sustain Target Pursuit during Visually Guided Prey-CatchingCurrent Biology 29:1771–1786https://doi.org/10.1016/j.cub.2019.04.064PubMedGoogle Scholar
- Molecular neuroanatomy and chemoarchitecture of the neurosecretory preoptic-hypothalamic area in zebrafish larvaeJournal of Comparative Neurology 522:1542–1564https://doi.org/10.1002/cne.23480PubMedGoogle Scholar
- Spinal Projection Neurons Control Turning Behaviors in ZebrafishCurrent Biology 23:1566–1573https://doi.org/10.1016/j.cub.2013.06.044PubMedGoogle Scholar
- An Introduction to Statistical LearningSpringer Google Scholar
- Contextual fear conditioning in zebrafishLearning and Memory 24:516–523https://doi.org/10.1101/lm.045690.117PubMedGoogle Scholar
- A 3D adult zebrafish brain atlas (AZBA) for the digital ageeLife 10:e69988https://doi.org/10.7554/eLife.69988PubMedGoogle Scholar
- Partial Least Squares (PLS) methods for neuroimaging: A tutorial and reviewNeuroImage 56:455–475https://doi.org/10.1016/j.neuroimage.2010.07.034PubMedGoogle Scholar
- Identification of a neuronal population in the telencephalon essential for fear conditioning in zebrafishBMC Biology 16https://doi.org/10.1186/s12915-018-0502-yPubMedGoogle Scholar
- Interindividual and sex differences in resilience and vulnerability to post-traumatic stress disorder (PTSD): insights from animal modelsBiology of Sex Differences 16:50https://doi.org/10.1186/s13293-025-00732-5PubMedGoogle Scholar
- The contextual brain: Implications for fear conditioning, extinction and psychopathologyNature Reviews Neuroscience 14:417–428https://doi.org/10.1038/nrn3492PubMedGoogle Scholar
- DeepLabCut: markerless pose estimation of user-defined body parts with deep learningNature Neuroscience 21:1281–1289https://doi.org/10.1038/s41593-018-0209-yPubMedGoogle Scholar
- Extending the analysis of zebrafish behavioral endophenotypes for modeling psychiatric disorders: Fear conditioning to conspecific alarm responseBehavioural Processes 149:35–42https://doi.org/10.1016/j.beproc.2018.01.020PubMedGoogle Scholar
- Spectral regularization algorithms for learning large incomplete matricesThe Journal of Machine Learning Research 11:2287–2322PubMedGoogle Scholar
- UMAP: Uniform Manifold Approximation and Projection for Dimension ReductionarXiv https://doi.org/10.48550/arXiv.1802.03426Google Scholar
- Partial least squares analysis of neuroimaging data: Applications and advancesNeuroImage 23:S250–S263https://doi.org/10.1016/j.neuroimage.2004.07.020PubMedGoogle Scholar
- Pectoral Fin Breeding Tubercle Clusters: A Method to Determine Zebrafish SexZebrafish 12:121–123https://doi.org/10.1089/zeb.2014.1060PubMedGoogle Scholar
- Darting across space and time: parametric modulators of sex-biased conditioned fear responsesLearning & Memory 29:171–180https://doi.org/10.1101/lm.053587.122PubMedGoogle Scholar
- The ecology of human fear: survival optimization and the nervous systemFrontiers in Neuroscience 9https://doi.org/10.3389/fnins.2015.00055PubMedGoogle Scholar
- The Everted Amygdala of Ray-Finned Fish: Zebrafish Makes a CaseBrain Behavior and Evolution 97:321–335https://doi.org/10.1159/000525669PubMedGoogle Scholar
- What is the thalamus in zebrafish?Frontiers in Neuroscience 6:64https://doi.org/10.3389/fnins.2012.00064PubMedGoogle Scholar
- The dorsal pallium in zebrafish, Danio rerio (Cyprinidae, Teleostei)Brain Research 1381:95–105https://doi.org/10.1016/j.brainres.2010.12.089PubMedGoogle Scholar
- Activation of the hypothalamic feeding centre upon visual prey detectionNature Communications 8:15029https://doi.org/10.1038/ncomms15029PubMedGoogle Scholar
- Connections of the lateral and medial divisions of the goldfish telencephalic palliumJournal of Comparative Neurology 494:903–943https://doi.org/10.1002/cne.20853PubMedGoogle Scholar
- Sensory Neurons Contacting the Cerebrospinal Fluid Require the Reissner Fiber to Detect Spinal Curvature In VivoCurrent Biology 30:827–839https://doi.org/10.1016/j.cub.2019.12.071PubMedGoogle Scholar
- Housing Conditions Differentially Affect Physiological and Behavioural Stress Responses of Zebrafish, as well as the Response to AnxiolyticsPLOS One 7:e34992https://doi.org/10.1371/journal.pone.0034992PubMedGoogle Scholar
- Neural dynamics and architecture of the heading direction circuit in zebrafishNature Neuroscience 26:765–773https://doi.org/10.1038/s41593-023-01308-5PubMedGoogle Scholar
- The Distribution of Fright Reaction and Alarm Substance Cells in FishesCopeia 1977:653–665https://doi.org/10.2307/1443164Google Scholar
- The Zebrafish Amygdaloid Complex – Functional Ground Plan, Molecular Delineation, and Everted TopologyFrontiers in Neuroscience 14:608https://doi.org/10.3389/fnins.2020.00608PubMedGoogle Scholar
- Development, circuitry, and function of the zebrafish cerebellumCellular and Molecular Life Sciences 80:1–20https://doi.org/10.1007/s00018-023-04879-5PubMedGoogle Scholar
- Strain- and context-dependent behavioural responses of acute alarm substance exposure in zebrafishBehavioural Processes 122:1–11https://doi.org/10.1016/j.beproc.2015.10.014PubMedGoogle Scholar
- Beyond bold versus shy: Zebrafish exploratory behavior falls into several behavioral clusters and is influenced by strain and sexBiology Open 11:bio059443https://doi.org/10.1242/bio.059443PubMedGoogle Scholar
- Whole-brain mapping in adult zebrafish and identification of the functional brain network underlying the novel tank testeNeuro 12https://doi.org/10.1523/ENEURO.0382-24.2025PubMedGoogle Scholar
- Mapping of Brain Activity by Automated Volume Analysis of Immediate Early GenesCell 165:1789–1802https://doi.org/10.1016/j.cell.2016.05.007PubMedGoogle Scholar
- Post-traumatic stress disorder: clinical and translational neuroscience from cells to circuitsNature Reviews Neurology 18:273–288https://doi.org/10.1038/s41582-022-00635-8PubMedGoogle Scholar
- Connections of the ventral telencephalon (subpallium) in the zebrafish (Danio rerio)Brain Research 1011:206–220https://doi.org/10.1016/j.brainres.2004.03.027PubMedGoogle Scholar
- . Putting Together Pieces of the Lateral Septum: Multifaceted Functions and Its Neural Pathwayseneuro 8:ENEURO.0315-21.2021https://doi.org/10.1523/ENEURO.0315-21.2021PubMedGoogle Scholar
- Silhouettes: A graphical aid to the interpretation and validation of cluster analysisJournal of Computational and Applied Mathematics 20:53–65https://doi.org/10.1016/0377-0427(87)90125-7Google Scholar
- Cannabinoid modulation of zebrafish fear learning and its functional analysis investigated by c-Fos expressionPharmacology Biochemistry and Behavior 153:18–31https://doi.org/10.1016/j.pbb.2016.12.005PubMedGoogle Scholar
- Cytoscape: A software Environment for integrated models of biomolecular interaction networksGenome Research 13:2498–2504https://doi.org/10.1101/gr.1239303PubMedGoogle Scholar
- Effects of different handling methods on the behavior of adult zebrafishPhysiology & Behavior 262:114106https://doi.org/10.1016/j.physbeh.2023.114106PubMedGoogle Scholar
- Discrete Time Markov Chains with RThe R Journal 9:84–104https://doi.org/10.32614/rj-2017-036Google Scholar
- Alarm substance induced behavioral responses in zebrafish (Danio rerio)Behavioural Brain Research 188:168–177https://doi.org/10.1016/j.bbr.2007.10.031PubMedGoogle Scholar
- The Emotional CerebellumThe Cerebellum 14:570–577https://doi.org/10.1007/s12311-015-0649-9PubMedGoogle Scholar
- Biological Network Exploration with Cytoscape 3Current Protocols in Bioinformatics 47:8–8https://doi.org/10.1002/0471250953.bi0813s47PubMedGoogle Scholar
- Alarm reaction in acquisition and social transmission of simulated-predator recognition by zebra danio fish (Brachydanio rerio)Journal of Comparative Psychology 104:101–112https://doi.org/10.1037/0735-7036.104.1.101Google Scholar
- Fear conditioning and the basolateral amygdalaF1000Research 9https://doi.org/10.12688/f1000research.21201.1PubMedGoogle Scholar
- From Pheromones to BehaviorPhysiological Reviews 89:921–956https://doi.org/10.1152/physrev.00037.2008PubMedGoogle Scholar
- Neuronal circuits for fear and anxietyNature Reviews Neuroscience 16:317–331https://doi.org/10.1038/nrn3945PubMedGoogle Scholar
- A deep learning algorithm for 3D cell detection in whole mouse brain image datasetsPLOS Computational Biology 17:e1009074https://doi.org/10.1371/journal.pcbi.1009074PubMedGoogle Scholar
- A neuronal blueprint for directional mechanosensation in larval zebrafishCurrent Biology 31:1463–1475https://doi.org/10.1016/j.cub.2021.01.045PubMedGoogle Scholar
- Chapter Nine - Alarm Pheromones—Chemical Signaling in Response to DangerIn:
- Litwack G
- Central connections of the olfactory bulb in the goldfish, Carassius auratusCell and Tissue Research 238:475–487https://doi.org/10.1007/BF00219862PubMedGoogle Scholar
- Zur Psychologie des Fisch-SchwarmesNaturwissenschaften 26:601–606https://doi.org/10.1007/bf01590598Google Scholar
- Individual differences in conditioned fear expression are associated with enduring differences in endogenous Fibroblast Growth Factor-2 and hippocampal-mediated memory performanceNeurobiology of Learning and Memory 134:248–255https://doi.org/10.1016/j.nlm.2016.07.021PubMedGoogle Scholar
- A bidirectional network for appetite control in larval zebrafisheLife 8:e43775https://doi.org/10.7554/eLife.43775PubMedGoogle Scholar
- The stress response in fishPhysiological Reviews 77:591–625https://doi.org/10.1152/physrev.1997.77.3.591PubMedGoogle Scholar
- Rethinking the Fear Circuit: The Central Nucleus of the Amygdala Is Required for the Acquisition, Consolidation, and Expression of Pavlovian Fear ConditioningThe Journal of Neuroscience 26:12387–12396https://doi.org/10.1523/JNEUROSCI.4316-06.2006PubMedGoogle Scholar
- Neural origins of basal diencephalon in teleost fishes: Radial versus tangential migrationJournal of Morphology 281:1133–1141https://doi.org/10.1002/jmor.21237PubMedGoogle Scholar
- The Central Nervous Organization of the Lateral Line SystemIn:
- Coombs S
- Bleckmann H
- Fay RR
- Popper AN
- Neural connections of the torus semicircularis in the adult ZebrafishJournal of Comparative Neurology 532:e25586https://doi.org/10.1002/cne.25586PubMedGoogle Scholar
- The organization of the zebrafish pallium from a hodological perspectiveJournal of Comparative Neurology 530:1164–1194https://doi.org/10.1002/cne.25268PubMedGoogle Scholar
- Neural connections of the pretectum in zebrafish (Danio rerio)Journal of Comparative Neurology 526:1017–1040https://doi.org/10.1002/cne.24388PubMedGoogle Scholar
- Involvement of the cerebellum in classical fear conditioning in goldfishBehavioural Brain Research 153:143–148https://doi.org/10.1016/j.bbr.2003.11.008PubMedGoogle Scholar
- Data from: Individual differences in fear memory expression engage distinct functional brain networksDryad Digital Repository https://doi.org/10.5061/dryad.sqv9s4nfh
Article and author information
Author information
Version history
- Sent for peer review:
- Preprint posted:
- Reviewed Preprint version 1:
- Reviewed Preprint version 2:
Cite all versions
You can cite all versions using the DOI https://doi.org/10.7554/eLife.107908. This DOI represents all versions, and will always resolve to the latest one.
Copyright
© 2025, Fontana et al.
This article is distributed under the terms of the Creative Commons Attribution License, which permits unrestricted use and redistribution provided that the original author and source are credited.
Metrics
- views
- 572
- downloads
- 22
- citations
- 2
Views, downloads and citations are aggregated across all versions of this paper published by eLife.