Extended Data Fig. 5: Spatial P value analysis, spatial distribution of neurons encoding exploitation state, exploration state, and transition from exploration to exploitation, and sensorimotor networks activated during hunting.
From: Internal state dynamics shape brainwide activity and foraging behaviour

a, The spatial P value analysis followed a two-step procedure. In step 1, ANTs registration was performed to transform the live fluorescent brain volumes of 17 animals into a common reference space defined by Z-Brain. In step 2, a spatial P value was calculated for each functionally classified neuron in each animal by examining its spatial colocalization across all 17 fish. For instance, to calculate the spatial P value of a functionally classified neuron in fish i (shown as red star), we calculate the shortest distance dr to any neuron in fish j that was classified into the same functional class to generate a same-class distance vector dri,1,…,dri,j−1,dri,j,…,dri,m, in which m = 17. We then calculated the shortest distance dn between the neuron in fish i and a random size-matched population of neurons in fish j obtained by randomly sampling all neurons in fish j, with the number of neurons sampled equal to the number of neurons in the functional class in fish j. Therefore, a randomized distance vector dni,1,…,dni,j−1,dni,j,…,dni,m was calculated. To facilitate comparison of these distance vectors, we reduce them to a single scalar value by calculating the mean of the lowest 90% of the distances within the same-class distance vector and random distance vector. We then repeated the random sampling process N times (N = 10,000 in our analysis) to construct a null distribution of the shortest distance between a functionally classified neuron in fish i and the randomly sampled neurons in other animals. We then fit this null distribution with a normal distribution. The P value for this functionally classified neuron in fish i relative to all other animals was then calculated by evaluating dr on the basis of a normal distribution model. We reject the null hypothesis of random sampling if a functionally classified neuron in fish i has a spatial P value < 0.025. b, The spatial density for each area in the Z-Brain map was calculated for neurons that encode exploitation (left), exploration (middle), and transition from exploration to exploitation (right). c–e, Brain regions with neural densities higher than two standard deviations (measured across all brain regions) for exploitation-state-encoding neurons (c), exploration-state-encoding neurons (d) and trigger neurons that encode the transition from exploration to exploitation (e) (n = 17 animals; only neurons with consistent spatial localization and spatial P value < 0.025 are considered for this analysis). f, Retinotopic map of prey detection neurons in the optic tectum. Left, anatomical position of neurons tuned to different prey angles (Methods). Right, angular tuning curves of optic tectum neurons classified by angle of peak prey response, in 30° increments. g, Location of all neurons time-locked to the onset of eye convergence. h, All neurons time-locked to successful prey ingestion. i, Retinotopic map for each prey detection angle depicted individually across eight maps. j, Motor networks that drive distinct movement types associated with pursuit and capture of prey. Motor networks were identified for all seven observed movement types. All panels depict neurons with spatially significant colocalization across animals (spatial P value < 0.025, n = 17 animals). Scale bars, 50 µm.