School of Data Science, University of Science and Technology of China, Hefei, China
Division of Life Science, The Hong Kong University of Science and Technology, Hong Kong SAR, China
Division of Life Sciences and Medicine, University of Science and Technology of China, Hefei, China
Hefei National Laboratory for Physical Sciences at the Microscale, Center for Integrative Imaging, University of Science and Technology of China, Hefei, China
Department of Precision Machinery and Precision Instrumentation, University of Science and Technology of China, Hefei, China
Department of Mathematics, The Hong Kong University of Science and Technology, Hong Kong SAR, China
The relationship between the geometric properties of the neural activity space and the size of neural assemblies.
A. Illustration of how dimensionality of neural activity (DPR) changes with the number of recorded neurons. B. The eigenvalues of the neural covariance matrix dictate the geometrical configuration of the neural activity space with being the distribution width along a principal axis. C. Examples of two neural populations with identical dimensionality (DPR = 25/11 ≈ 2.27) but different spatial configurations, as revealed by the eigenvalue spectrum (green: {λi} = {7, 7, 1}, blue: {λi} = {9, 3, 3}).
Whole-brain calcium imaging of zebrafish neural activity and the phenomenon of its scale-invariant covariance eigenspectrum.
A. Rapid light-field Ca2+ imaging system for whole brain neural activity in larval zebrafish. B. Inferred firing rate activity from the brain-wide calcium imaging. The ROIs are sorted by their weights in the first principal component (23). C. Procedure of calculating the covariance spectrum on the full and sampled neural activity matrices. D. Dimensionality (circles, average across 8 samplings (dots)), as a function of the sampling fraction. The curve is the predicted dimensionality using Eq. (5). E. Iteratively sampled covariance matrices. Neurons are sorted in each matrix to maximize values near the diagonal. F. The covariance spectra, i.e., eigenvalue vs. rank/N, for randomly sampled neurons of different sizes (colors). The gray dots represent the sorted variances Cii of all neurons. G to I. Same as F but from three models of covariance (see details in Methods): (G) a Wishart random matrix calculated from a random activity matrix of the same size as the experimental data; (H) replacing the eigenvectors by a random orthogonal set; (I) covariance generated from a randomly connected recurrent network.
ERM model of covariance and its eigenspectrum.
A. Schematic of the Euclidean Random Matrix (ERM) model, which reorganizes neurons (circles) from the anatomical space to the functional space (here d = 2 is a two-dimensional box). The correlation between a pair of neurons decreases with their distance in the functional space according to a kernel function . This correlation is then scaled by neurons’ variance (circle size) to obtain the covariance Cij. B. An example ERM correlation matrix (i.e., when ). C. Spectrum (same as Fig. 2F) for the ERM correlation matrix in B. The gray dots represent the sorted variances Cii of all neurons (same as in Fig. 2F). D. Visualizing the distribution of the same ERM eigenvalues in C by plotting the probability density function (pdf).
Three factors contributing to scale invariance.
A. Impact of µ and d (see text) on the scale invariance of ERM spectrum (same plots as Fig. 3C) with . The degree of scale invariance is quantified by the collapse index (CI), which essentially measures the area between different spectrum curves (upper right inset). For comparison, we fix the same coordinate range across panels hence some plots are cropped. The gray dots represent the sorted variances Cii of all neurons (same as in Fig. 2F). B. Top: sampled correlation matrix spectrum in an example animal (fish 1). Bottom: Same as top but for the covariance matrix that incorporates heterogeneous variances. The gray dots represent the sorted variances Cii of all neurons (same as in Fig. 2F). C. The CI of the correlation matrix (filled squares) is found to be larger than that for the covariance matrix (opened squares) across different datasets: f1 to f6: six light-field zebrafish data (10 Hz per volume, this paper); fl: light-sheet zebrafish data (2 Hz per volume, (33)); mn: mouse Neuropixels data (downsampled to 10 Hz per volume); mp: mouse two-photon data, (3 Hz per volume, (23)).
The relationship between the functional and anatomical space and theoretical predictions.
A. Three sampling methods (A1) and RCCA (see text). When RCCA ≈ 0 (A2), the anatomical sampling (ASap) resembles the random sampling (RSap), and while when RCCA ≈ 1 (A4), ASap is similar to the functional sampling (FSap). B. Distribution of neurons in the functional space inferred by MDS. Each neuron is color-coded by its projection along the first canonical direction in the anatomical space (see text). Data based on fish 6, same for C to E. C. Similar to B. but plotting neurons in the anatomical space with color based on their projection along in the functional space (see text). D. Dimensionality (DPR) across sampling methods: average DPR under RSap (circles), average and individual brain region DPR under ASap (squares and dots), and DPR under FSap for the most correlated neuron cluster (triangles; Methods). Dashed and solid lines are theoretical predictions for DPR under RSap and FSap, respectively (Methods). E. The CI of correlation matrices under three sampling methods in 6 animals (colors). **p<0.01; ***p<0.001; one-sided paired t tests: RSap vs. ASap, p = 0.0010; RSap vs. FSap, p = 0.0004; ASap vs. FSap, p = 0.0014.
Flat: when ,. Tangent: when follows a tangent line of the exact power law ( and have a same first-order derivative when ). b and c are constants. Tent: when follows a straight line while the slope is not the same as the tangent case. Parabola: when follows a quadratic function (ax2 + 1 and have same first-order derivative). t pdf: mimic the smoothing treatment like the t distribution. All the constant parameters are set such that f (0) = 1.
A. Spatial distribution of segmented ROIs (shown in different colors). There are 1347 to 3086 ROIs in each animal. Scale bar, 100 µm. B. Explained variance of the activity data by PCs up to 500 rank. The different colored lines represent different fish data (n=6).
The phenomenon of scale-invariant eigenspectra across different datasets.
A-D. Distribution of normalized pairwise covariances, where (Methods). E-H. Sampled covariance eigenspectra of different datasets. I-L. Pdfs of sampled covariance matrix eigenspectra of different datasets. The datasets correspond to the following examples: column 1: fish data (from fish 1, all fish data are shown in Fig. S10A-F) from whole brain light-field imaging; column 2: fish data from whole brain light-sheet imaging; column 3: mouse data from multi-area Neuropixels recording; column 4: mouse data from two-photon visual cortex recording.
Comparison between ERM simulation and theory.
A-C. Rank plots of the normalized eigenspectra (λ/ρ), with the simulations obtained using correlation matrix (sim: corr, and covariance matrix (sim: cov, neuron’s activity variance is i.i.d. sampled from a log-normal distribution with zero mean and a standard deviation of 0.5 in the natural logarithm of the values; we also normalize (Methods)). The curves between “sim: corr” and “sim: cov” are nearly identical in panels A and B. The theoretical predictions of normalized eigenvalues λ/ρ are obtained using the high-density theory (cyan, Eq. (12)). The density ρ decreases from panel A to panel C (ρ = 1024, 256, 10.24 respectively). D-F. Numerical validation of the theoretical spectrum by comparing probability density functions for increasing density of covariance ERM (ρ = 1024, 256, 10.24 respectively). Other simulation parameters: N = 1024, d = 2, L = (N/ρ)1/d, μ = 0.5, ϵ = 0.03125. The ERM simulations were conducted 100 times. The results are presented as the mean ± SEM.
Covariance spectra under different kernel functions .
The figure presents both the sampled eigenvalue rank plot and the pdf of ERM with different functions and varying dimensions d, where panels A-D,I,J. display the rank plot and panels E-H,K,L. show the pdf of ERM. A,E. Exponential function where b = 1 and dimension d = 2. B,F. Exponential where b = 1 and dimension d = 3. C,G. Gaussian pdf where and dimension d = 2. D,H. Gaussian pdf where and dimension d = 3. I,K. t pdf (Eq. (11)) and dimension d = 2. J,L. t pdf (Eq. (11)) and dimension d = 3. The ERM simulations were conducted 100 times and each ERM used an identical sampling technique described in (Methods). The results represent mean ± SEM. M. Summary of CI’s for different and d. On the x-axis labels, ‘e’ denotes the Exponential function ,’g’ denotes the Gaussian pdf ,’t’ denotes the t-distribution pdf ,while ’2’ and ’3’ indicate d = 2 or d = 3, respectively.
Impact of η and d on the scale invariance of covariance eigenspectra in the ERM with .
The columns from left to right correspond to η = 0.3, 0.5, 0.7, 0.9, and the rows from top to bottom correspond to d = 1, 2, 3 (Eq. (2) and Eq. (11)). Other ERM simulation parameters: N = 4096, ρ = 256, L = (N/ρ)1/d,ϵ = 0.03125 and σ2 = 1. Each panel shows a single ERM realization. For visualization purposes, the views in some panels are truncated since we use the same range for the eigenvalues in all panels.
Impact of heterogeneous activity levels on the scale invariance.
A. The CI as a function of the heterogeneity of neural activity levels .We generate ERM where each neuron’s activity variance is i.i.d. sampled from a log-normal distribution where the logarithm of the variable follows a normal distribution with zero mean and a sequence of standard deviation (0, 0.05, 0.1,…, 0.5) in the natural logarithm of the values .We also (Methods). The solid blue line is the average across 100 ERM simulations, and the shaded area represents the SD. The red line results from the Gaussian variational method with simulation value integration limit .The green line is the result of the Gaussian variational method with high-density value integration limit (Methods). ρ0 = 128. B. Same as A, but with a smaller ρ0 = 10.24. Other parameters: μ = 0.5, d = 2, N = 1024, L = (N/ρ)1/d, ϵ = 0.03125. C. The collapse index (CI) of the correlation matrix (filled symbols) is larger than that of the covariance matrix (opened symbols) across different datasets excluding those shown in Fig. 4. We use 7,200 time frame data across all the datasets. l2 to l3: light-sheet zebrafish data (2 Hz per volume); n2 to n3: Neuropixels mouse data, downsampled to 10 Hz per volume, p2 to p3: two-photon mouse data, (3 Hz per volume).
Modifications of near x = 0.
The upper row illustrates the slow-decaying kernel function (blue solid line) and its power-law asymptote (red dashed line) along a 1D slice at various .The lower row is similar to A, but on the log-log scale. The formulas for different ’s are listed in table S3 in Methods.
Comparisons of large eigenvalues across different smoothing interval sizes, ϵ.
Rank plot (upper row) and pdf (lower row) of the covariance eigenspectrum for ERMs with different .A. ϵ = 0.06. B. ϵ = 0.12. C. ϵ = 0.3. D. ϵ = 0.6. Other ERM simulation parameters: N = 4096, ρ = 100, μ = 0.5, d = 2, L = 6.4, .The formulas for different ’s are listed in table S3 in Methods.
Factors that do not affect the scale invariance.
A. Rank plot of the covariance eigenspectrum for ERMs with different (see table S3). Diagrams show different slow-decaying kernel functions along a 1D slice. B. Same as A but for different coordinate distributions in the functional space (see text). The diagrams on the right illustrate uniform and clustered coordinate distributions. C. Same as A but for different geometries of the functional space (see text). Diagrams illustrate spherical and hemispherical surfaces. D. CI of the different ERMs considered in A-C. The range on the y-axis is identical to Fig. 4C. On the x-axis, 1: uniform distribution, 2: normal distribution, 3: log-normal distribution, 4: uniform two nearby clusters, 5: uniform two faraway clusters, 6: uniform 3-cluster, 7: spherical surface in ℝ3, 8: hemispherical surface in ℝ3. All ERM models in B, C are adjusted to have a similar distribution of pairwise correlations (Methods).
Fitting ERM to zebrafish data from our experiments (part 1).
Comparison of sampled covariance eigenspectra in fish data and fitted ERM models. The columns correspond to six light-field zebrafish data: fish 1 to fish 6. Number of time frames: fish 1 - 7495, fish 2 - 9774, fish 3 - 13904, fish 4 - 7318, fish 5 - 7200 and fish 6 - 9388. A-F. sampled covariance eigenspectra for different fish data. G-L. Same as A-F but for ERM models with fitted parameters (μ/d, L), functional coordinates inferred using MDS, and the experimental σi. M-R. Same as A-F but for ERM models with fitted parameters (μ/d, L), uniform distributed functional coordinates, and a log-normal distribution of σ2. μ/d = [0.456, 0.258, 0.205, 0.262, 0.302, 0.308] in fish 1-6.
Fitting ERM to all six zebrafish data from our experiments (part 2).
Comparison of the covariance matrix between fish data and our fitted model. The columns correspond to six light-field zebrafish data: fish 1 to fish 6. A-F. The covariance matrix of different fish data. G-L. The covariance matrix of ERM models with fitted parameters (μ, L) and functional coordinates inferred using MDS and the experimental σi.
Fitting ERM to all six zebrafish data from our experiments (part 3).
Columns correspond to five light-field zebrafish data: fish 1 to fish 6. A-F: Comparison of the power-law kernel in the model (blue line) and the correlation-distance relationship in the data (red line). The distance is calculated from the inferred coordinates using MDS. The shaded area represents the SD. G-L: Same as A-D but on the log-log scale.
Fitting ERM to all six zebrafish data from our experiments (part 4).
Columns correspond to 6 light-field zebrafish data: fish 1 to fish 6. A-F: CCA correlation between the first CCA variables with different embedding dimensions in the functional space. Blue line indicates the CCA correlation of example fish data, green line shows the CCA correlation of example fish data with shuffled functional coordinates, and error bars represent the SD.
Relationship between the functional space and anatomical space for each zebrafish dataset from our experiments.
Columns correspond to five light-field zebrafish data: fish 1 to fish 5 (with fish 6 has been shown in Fig. 5). A-E. Distribution of neurons in the functional space, where each neuron is color-coded by the projection of its coordinate along the canonical axis in anatomical space (see text in Result section 2.4). Arrow: the first CCA direction in functional space. F-J. Distribution of neurons in the anatomical space with the forebrain neuron located on the left side and the hindbrain neuron on the right side. Each neuron is color-coded by the projection of its coordinate along the canonical axis in functional space (see text in Result section 2.4). Arrow: the first CCA direction in anatomical space.
The effects of hunting behavior on scale invariance and functional space organization.
A,B. sampled covariance eigenspectra of the data from fish 1 calculated from control (A) and hunting removed (B) data. Ctrl: We randomly remove the same number of non-hunting frames. This process is repeated 10 times, and the mean±SD of the CI is shown in the plot. Hunting removed: The time frames corresponding to the eye-converged intervals (putative hunting state) are removed when calculating the covariance (Methods). The CI for the hunting-removed data appears to be statistically smaller than in the control case (p-value= 1.5 × 10−9). C. Functional space organization of control data. The neurons are clustered using the Gaussian Mixture Models (GMMs) and their cluster memberships are shown by the color. The color bar represents the proportion of neurons that belong to each cluster. D. Similar to C but the functional coordinates are inferred from the hunting-removed data. The color code of each neuron is the same as that of the control data (C), which allows for a comparison of the changes to the clusters under the hunting-removed condition. See also the Movie. S1. E. Fold change in size / area (Methods) for each cluster (top; the gray dashed line represents a fold change of 1, that is, no change in size) and the anatomical distribution of the most dispersed cluster (bottom).
Removing the time segment of hunting behavior does not obliterate the scale-invariant eigenspectra.
Rows correspond to 4 light-field zebrafish data: fish 2 to fish 5 (results for fish 1 have been shown in Fig. S15). A,C,E,G. Ctrl: we randomly remove the same number of time frames that are not the putative hunting frames. We repeat this process 10 times to generate 10 control covariance matrices and the CI is represented by mean±SD. B,D,F,H. Hunting removed: data obtained by removing hunting frames from the full data (Methods). The CI for the hunting removed data appears to be significantly smaller than that of the control case (one-sample t-test p = 2.2 × 10−10 in fish 2, p = 4.6 × 10−9 in fish 3, p = 1.7 × 10−9 in fish 4, and p = 3.4 × 10−17 in fish 5).
Hunting behavior reorganizes neurons in the functional space
Rows correspond to 5 light-field recordings of zebrafish engaged in hunting behavior: fish 1 to fish 5. A,D,G,J,M. (top) Functional space organization of the control data inferred by fitting the ERM and MDS (section 2.4). Neurons are clustered using the Gaussian Mixture Models (GMMs) and their cluster memberships are shown by the color. The colorbar represents the proportion of neurons belonging to each cluster. A,D,G,J,M. (bottom) The coordinate distribution of the cluster in control data which is most dispersed (i.e., largest fold change in size, see below) after hunting-removal. The transparency of the dots (colorbar) is proportional to the probability of the neurons belonging to this cluster (Methods). The cyan ellipse serves as a visual aid for the cluster size: it encloses 95% of the neurons belonging to that cluster (Methods). B,E,H,K,N. (top) Similar to A,D,G,J,M. (top) but the functional coordinates are inferred from the hunting-removed data. The color code of each neuron is the same as that in the control data, which allows for a comparison of the changes to the clusters under the hunting-removed condition. B,E,H,K,N. (bottom) Similar to A,D,G,J,M. (bottom) but the functional coordinates are inferred from the hunting-removed data. The transparency of each neuron is the same as in A,D,G,J,M. (bottom), and it represents the probability pik (Methods) of neurons belonging to the most dispersed cluster k in the control data. Likewise, the cyan ellipse encloses 95% of the neurons belonging to that cluster (Methods). C,F,I,L,O. Top, size/area fold change (Methods) for each cluster (the gray dashed line represents a fold change of 1, i.e., no change in size); bottom, the anatomical distribution of the neurons in the most dispersed cluster.
Negative covariances do not affect the eigenspectrum of the zebrafish data.
Red: eigenspectrum of the original data covariance matrix. Blue: eigenspectrum of the covariance matrix with negative entries replaced by zeros. In this figure, all neurons recorded in each fish were utilized without any sampling.
Eigenspectra of RG-inspired clustering, direct functional region sampling (FSap), and random sampling (RSap) in ERM.
A,D. Renormalization-Group (RG) clustered eigenspectra of ERM. The size of the cluster is denoted by N, which is the number of neurons in each cluster. We adopt the RG approach (20, 67), but with a specific modification (Methods). B,E. Direct spatial sampling in the functional space (FSap) and the corresponding ERM eigenspectra. We began our analysis with a set of N0 neurons distributed in the functional space. Initially, we chose N = N0/2 neurons that were located exclusively on one side of the x-axis of this space. We then proceeded to select N = N0/4 neurons from 4 quadrants. This sampling process was repeated iteratively, generating successively smaller subsets of neurons. C,F. Random sampled (RSap) eigenspectra of ERM. ERM parameters: A-C Exponential function where b = 1, ρ = 10.24 and dimension d = 2. D-F Approximate power law Eq. (11) with μ = 0.5, ρ = 10.24 and dimension d = 2. Other parameters are the same as Fig. 3. The standard error of the mean (SEM) across the clusters is represented by the shaded area of each line.
Dimensionality (DPR) across sampling methods in fish data.
A-F Result from fish 1 to fish 6: mean RSap DPR (circles), mean (squares) and individual ASap DPR, and FSap’s most correlated cluster DPR (triangles). Dashed and solid lines indicate RSap and uniform FSap theoretical predictions, respectively. ERM parameter: μ = 0.6, d = 2, functional coordinates follow a multivariate normal distribution with variance , anatomical coordinates follow a multivariate normal distribution with variance .
Dimensionality (DPR) across sampling methods in ERM.
PR dimensionality result of ERM model, coordinate in funcitonal and anatomical space are multivariate Gaussian distribution, the CCA correlation between funcitonal and anatomical space are RCCA = 0.4, 0.6, 0.8 in A-C. Mean RSap DPR (circles), mean (squares) and individual ASap DPR, and FSap’s most correlated cluster DPR (triangles). Dashed and solid lines indicate RSap and uniform FSap theoretical predictions, .
Example of Renormalization Group (RG) approach for a set of eight neurons.
The figure is adapted from (20). The diagram illustrates the iterative clustering process for eight neurons. In each iteration, neurons are paired based on maximum correlation, with their activities combined through summation and normalized to maintain unit mean for nonzero values. Each neuron can only be paired once per iteration, ensuring all neurons are grouped by the iteration’s end.
Morrell et al.’s latent variable model.
A-D: Functional sampled (FSap) eigenspectra of the Morrell et al. model. E-H: Random sampled (RSap) eigenspectra of the same model. Briefly, in Morrell et al.’s latent variable model (36, 52), neural activity is driven by Nf latent fields and a place field. The latent fields are modeled as Ornstein-Uhlenbeck processes with a time constant τ. The parameters ϵ and η control the mean and variance of individual neurons’ firing rates, respectively. The following are the parameter values used. A,E: Using the same parameters as in (52): Nf = 10, ϵ = −2.67, η = 6, τ = 0.1. Half of the cells are also coupled to the place field. B,C,D,F,G,H: Using parameters from (36): Nf = 5, ϵ = −3, η = 4. There is no place field. The time constant τ = 0.1, 1, 10 for B,F, C,G, and D,H, respectively.
Scale-invariant properties persist across different temporal sampling rates in neural recordings.
Analysis of multi-area Neuropixels recordings (23) from 1024 neurons, downsampled to different rates resulting in 7200 time frames per condition (6 Hz, 12 Hz, 18 Hz, and 24 Hz; columns 1-4 respectively). A-D. Distribution of pairwise covariances after normalization to unit variance (, see Methods). E-H. Eigenvalue spectra of the covariance matrices, showing similar power-law scaling across sampling rates. I-L. Probability density functions (PDFs) of the eigenvalues, demonstrating that the characteristic shape of the distribution is preserved across different temporal resolutions.
Table of notations.
Calculate gi and gr.
A. The path of the contour integral for gi, gr (Eq. (S67)). B-C. The heatmap of gr and gi with respect to λ and ρ. gi, gr in B, C are calculated by the numerical method (section 6.5.1). The parameters are N = 1024, ρ = 10.24, d = 2, L = 10, µ = 0.5, ϵ = 0.03125. is i.i.d. sampled from a log-normal distribution with zero mean and a standard deviation of 0.5 in the natural logarithm of the values; we also normalize .
Relationship between ratioh and z.
A. ρ = 1024, B. ρ = 256. Blue line: ratioh calculated numerically. Red line: 100-order expansion of Eq. (S101), which perfectly overlaps with the blue line. Green line: expansion to the first order. Other parameter: µ = 0.5, d = 2, ϵ = 0.03125. C. Relationship between ρϵd and dimension d with fixed (Eq. (S105)).
Wick rotation in complex plane
Neural activity patterns in anatomical and functional space during hunting (click here).
Single-trial examples of fish 1 and fish 3. A. Inferred firing rate activity in anatomical space. Scale bar, 100 µm. B. Inferred firing rate activity in functional space. Functional space organization of the control data inferred by fitting the ERM and MDS in section 2.4. The cyan ellipse serves as a visual aid for the cluster size: it encloses 95% of the neurons belonging to that cluster (Methods). The inset illustrates the functional space organization, similar to that shown in Fig. S15C. The colorbars in panels A and B depict the inferred activity magnitude of individual neurons. C. Simultaneous behavior recording alongside the neural activity.