Introduction

The structural and functional development of the human brain is in a hierarchical manner, which from the lower-level primary sensory cortices to higher-level transmodal association cortices that support complex cognitive functions1. Longitudinal studies have demonstrated that the hierarchical changes in structural maturation are coupled with developmental variability in functional networks from neonate to adolescence2,3,4. Especially, developmental changes of the primary-to-transmodal gradient are associated with cognitive growth during childhood and adolescence, such as working memory5 and executive performance6, and a reduction of the excitation-to-inhibition ratio is found in association cortex7. However, how brain development in childhood and adolescence is linked to the establishment of brain networks remains understudied. One question is whether the multiple patterns of brain function can enable effective identification of single developing individuals.

Researchers have realized that among healthy populations, there is widespread interindividual diversity in brain structure and function8. Neuroimaging studies of brain morphology with large sample sizes showed the changes in brain structure and the rate of changes9, the age at peak growth of cerebral cortices, and the decline of age10 over the lifespan. Researchers also demonstrated that some identified genes affect the rates of early development and neurodegenerative processes in brain structures11,12, and the development changes of brain network in primary-to-transmodal gradient are associated with the expression levels of related genes5. Previous neurobehavioral studies also demonstrated that in different ages, high-level cognitive ability is associated with distinct neural bases13. In addition, the functional connectivity derived from functional magnetic resonance imaging (fMRI) in both task and rest conditions can also be used to distinguish the adult individuals as a ‘fingerprint’14. Therefore, multiple factors can be valuable to identify individual-specific brain developmental status.

The structural and functional networks are critical features for identifying disorders during development15. Recently, many studies have adopted abnormalities of brain structure and functional connectivity as biomarkers for disease diagnosis. For illustration, a higher residual variance of white matter may indicate children with autistic spectrum disorder (ASD)16; preadolescents with high anxiety and enhanced impulsivity have thicker prefrontal and temporal cortices17; children but not adolescents and adults with attention deficit hyperactivity disorder (ADHD) show lower surface area in frontal, cingulate, and temporal regions18. For functional remarks, a delay in stable and individual functional networks is related to undermined mental health during adolescence19; reduced functional connectivity of the amygdala with dorsolateral and the ventromedial prefrontal cortices are seen in depressive adolescents20.

However, due to the interindividual diversity in brain structure, functional pattern, and developmental dynamics, both the spatial and temporal patterns of brain networks in the maturation process and their influences on mental health are requested. We have not yet discussed whether it is necessary to employ a multimodality brain network in spatiotemporal space to identify individuals during development, especially those with diseases. To verify these issues, both resting-state electroencephalography (EEG) and fMRI data from the Child Mind Institute Biobank, including children, adolescents, and adults, were used in this study. We first assessed the temporal dynamics of brain network based on resting-state EEG data, which is called the microstate. The microstate indicates the instantaneous state of global neuronal activity21. We hypothesized that the dominance and stability of dynamic brain states would depict different populations during development. Secondly, we evaluated the spatial features of functional networks based on resting-state fMRI data. We hypothesized that the changes in static and dynamic brain connectivity patterns would not only exhibit the characteristics of intrinsic functional networks during development but also reflect the between-network coupling. Finally, we combined the temporal and spatial properties of brain network to identify normal individuals across different age stages, and distinguish healthy individuals and individuals with mental disorders during development.

Results

Individual variation of the temporal dynamics in normative brain growth

To link the individual difference in dynamic brain states to growth status, we first investigated the age-related variation of EEG microstate maps in 187 healthy individuals with ages ranging from 5 to 44 years. We identified four subject-level microstate maps using k-means clustering based on EEG data filtered by 2–20 Hz, 1–40 Hz, theta, alpha, beta, and low gamma bands, respectively (see Methods and materials). To examine the spatial configurations of the four maps in healthy individuals during development, we computed the group-averaged microstate maps within 2-20 Hz across adults (age > 18 years) and across children (age = 5 years) respectively. The four microstate maps of healthy adults were ranked according to their appearing probability, and labeled as map A exhibited an anterior-posterior orientation, map B exhibited a frontal-central maximum, map C exhibited a right-left orientation and map D exhibited a left-right orientation (Fig. 1a), which were highly consistent with previous studies21,22. For the four microstate maps generated from healthy children, their spatial configurations had high similarities with those generated from healthy adults (Fig. 1b), which imply a stable spatial configuration of microstate maps during development. However, the multivariate analysis of variance (MANOVA) using age and spatial configuration as fixed factors showed that the probabilities of map C and D in healthy children were larger than those in healthy adults (Fig. 1c, p = 0.0007). There is an interaction between age and spatial configuration. Previous studies demonstrated that map A and B reflect attention and saliency networks, and map C and D are associated with visual and auditory sensory networks23. Therefore, the more probabilities of map C and D suggest that the sensory networks may contribute more to brain function in the early development. We then averaged the map A and B to get a Map AP, which showed an anterior-posterior orientation; and averaged the map C and D to get a Map LR, which showed a left-right orientation.

Fig. 1: EEG patterns of microstate maps at rest across ages.
figure 1

a The global pattern of microstate maps was calculated from 2–20 Hz frequency band, averaged from healthy adults (left, age >18 years, n = 34) and children (right, age = 5 years, n = 11). b The spatial similarity between the microstate maps of adults and those of children. The digits in the matrix indicate correlation coefficient. c The probability distribution of microstate map A–D in adults and children groups. Square dots indicate mean probabilities. Error bars indicate standard error. Circle dots indicate individual probabilities. The calculations of both (b) and (c) were based on maps shown in (a). d The global pattern of microstate maps was calculated from 1–40 Hz frequency band, with the same format as (a). e The spatial similarity of microstate maps between the frequency bands of 2–20 Hz and 1–40 Hz, which were generated from healthy adults. The digits in the matrix indicate correlation coefficient. f The probability distribution of microstate map A–D in adults and children groups was calculated from maps shown in (d). g, h The distribution of microstate parameters ΔCρ, duration, occurrence, and transition probability across ages (n = 187), which calculated from microstate maps with 2–20 Hz (g) and 1– 40 Hz (h) frequency bands, respectively. Blue dots show individual values of ΔCρ, and individual values of duration, occurrence, and transition probability of Map AP. Red dots show individual values of duration, occurrence, and transition probability of Map LR. Polynomial models explain the changes in ΔCρ (blue line and R2), duration, occurrence, and transition probability of Map AP (blue line and R2), and those of Map LR (red line and R2) as a function of age. The coefficient of determination (R2) indicates the fitting performance.

We then extended the frequency band of EEG data to 1–40 Hz, to examine the influence of frequency on microstate maps. By filtering the EEG data to 1–40 Hz we also obtained four microstate maps with well-defined spatial configurations in healthy adults and children (Fig. 1d). The similarities of the four maps between 1–40 Hz and 2–20 Hz were remarkably high, which could reach 99% (Fig. 1e). Whereas the interaction between age and spatial configuration was not significant in 1–40 Hz data (p = 0.113, Fig. 1f). Moving to the characteristic frequencies of EEG, the MANOVA showed significant interaction between age and spatial configuration in microstate maps that generated from theta (p = 0.048), alpha (p = 0.001), beta (p = 0.007) and low gamma (p = 0.006) bands data (Supplementary Fig. 1a). We got similar results that the healthy children presented relatively lower probabilities of Map AP than healthy adults. Among the four characteristic frequencies, the alpha band showed a typical opposite pattern of the four maps between adults and children (Supplementary Fig. 1a). Thus, we inferred that the alpha band may contribute more to the interaction effect between age and spatial configurations. To characterize the dominance of spatial configurations during development, we calculated ΔCρ, the probability-weighted spatial correlation difference between Map AP and LR (see Methods and materials). The higher the ΔCρ, the more dominant the Map AP. A first- (theta band), second- (2–20 Hz, 1–40 Hz, alpha and low gamma bands), and third-order (beta band) polynomial model was employed to fit the variations of ΔCρ across ages (Fig. 1g, h; Supplementary Fig. 1b–e). The ΔCρ is well predicted by age in each frequency band, except in low gamma band. We found that the dominance of Map AP, which indicates the attention and saliency networks, increases during development, and could decrease in middle-aged people.

To delineate the activity of microstate maps evolves with age, we further quantified the duration (how long a given map remains stable), occurrence (how many times a given map occurs in 1 s), and transition probability of individual maps. The data from 2–20 Hz and from 1–40 Hz have consistent results. We used a second-order polynomial model to fit the relationship between the duration of maps and ages, and observed that the duration of both Map AP and LR became shorter during development and became longer in middle-aged people (Fig. 1g, h). Compared with Map AP, the variations in Map LR’s duration had a higher correlation with age. We then used a third-order polynomial model to fit the association between occurrence/transition probability and age. The ages make better predictions in the occurrence and transition of Map AP than those of Map LR, and we found that the occurrence and transition of Map AP increased during the development and began to decrease in middle-aged people (Fig. 1g, h). The corresponding results in theta, alpha, beta, and low gamma bands are shown in Supplementary Fig. 1b–e. The combination of increased ΔCρ, higher occurrence and transition probability of Map AP imply that the Map AP which represents higher-level cognition will become more dominant and active with the development of brain, while the smaller ΔCρ and longer Map LR’s duration suggest that the Map LR which represents sensory networks is more dominant but less active in the early development and aging stage.

Within-disease variation of temporal dynamics during brain development

To determine whether the variations of microstate parameters also exist in individuals with mental disorders during development, we quantified the age-related changes of six disease populations, including individuals with anxiety, depression, ADHD, ASD, learning disorder (LD), and with the clinical evaluation of language fundamentals that below criterion (referred as CELF below). Based on the fitting results that predicted microstate parameters by age in healthy individuals, we found that both Map LR’s duration and Map AP’s occurrence generated from 1–40 Hz had an R2 > 0.5, which indicates a better fitting and the fitting model could explain more than 50% variance in the data. Therefore, the microstate parameters derived from 1–40 Hz were selected for further analyses below.

We first examined the microstate parameters between healthy individuals and the six disease populations regardless of age using two-sample t test (Fig. 2a, d; Supplementary Fig. 2a, d, for subject information see Supplementary Table 1). Compared with healthy individuals, the population with ADHD and with CELF showed lower occurrences of Map AP (pADHD = 9.9 10−9; pCELF = 0.001) and LR (pADHD = 1.6 10-6; pCELF = 0.002), and longer durations of Map AP (pADHD = 1.3 10−5; pCELF = 0.008) and LR (pADHD = 1.8 10−5; pCELF = 0.022). The population with ASD exhibited decreased occurrences of Map AP (p = 0.009) and LR (p = 0.002), and increased durations of Map AP (p = 0.001). The population with anxiety and LD only exhibited lower occurrence in Map AP (panxiety = 0.018; pLD = 0.031). Whereas the population with depression exhibited a larger occurrence in Map AP (p = 0.033) and shorter duration in Map LR (p = 0.007). Then we compared these microstate parameters between healthy and disease population at specific age stages, including childhood (5–9 years), early adolescence (10–13 years), middle adolescence (14–17 years), late adolescence (18–21 years), or adult (18–44 years). The result showed that there was no significant difference in parameters between healthy and disease population within a single age stage but could be seen across age stages (Fig. 2b, e; Supplementary Fig. 2b, e). Pearson’s correlation indicates a significant increase in Map AP’s occurrence and a reduction in Map LR’s duration during development in anxiety, depression, ADHD, ASD, and CELF populations (Fig. 2c, f). However, during development, the growth of Map LR’s occurrence was only seen in individuals with depression, ADHD, and CELF (Supplementary Fig. 2c), and the reduction of Map AP’s duration was only seen in individuals with ADHD and CELF (Supplementary Fig. 2f). These age-related changes reflected that the increased activity of Map AP that represent higher-level cognition and reduced dominance of Map LR that represent sensory networks are also prominent in disease population, hence considering the influence of brain development on brain networks when making diagnosis is essential.

Fig. 2: Duration and occurrence changes of microstate maps across ages in different diseases.
figure 2

a The distribution of Map AP’s occurrence in seven populations (nHealthy = 187, nAD = 122, nDD = 53, nADHD = 435, nASD = 87, nCELF = 293, nLD = 68). The ages of healthy population range from 5 to 44 years, while the ages of all other populations range from 5 to 21 years. the two-sample t-tests (two-sided) were conducted between the healthy population and the other six populations, respectively. Boxes represent interquartile range (IQR), central lines indicate the median, whiskers indicate 1.5 × IQR and dot symbols indicate outliers. AD: anxiety disorder; DD: depression disorder; ADHD: attention deficit hyperactivity disorder; ASD: autism spectrum disorder; CELF: below clinical evaluation of language fundamentals criterion; LD: learning disorder. b The one-by-one comparison of Map AP’s occurrence between healthy population and seven populations at four ages (one-way ANOVA, Dunnett corrected). The color bar indicates the log10(p-value) of each paired comparison. c The association between Map AP’s occurrence and individual age in six populations with diseases. df The duration of Map LR, with the same format as (ac). *p < 0.05, **p < 0.01, and ***p < 0.001.

Spatial-temporal variation of functional networks during brain development

To associate the individual difference in brain functions to growth, we next performed spatial and temporal analyses based on functional networks in resting-state fMRI data in healthy individuals and six disease populations (for subject information see Supplementary Table 1), including individuals with anxiety, depression, ADHD, ASD, LD and CELF. The group spatial independent component analysis (ICA) was used to detect the static functional connectivity of individuals, which indicated spatial variations of functional networks. In a group of healthy individuals that older than 18 years, we used group-level ICA to identify 7 functional networks (Fig. 3a) and defined them as 7 independent components (ICs) respectively, including frontal-parietal network (FPN, IC1), default mode network (DMN, IC2), sensorimotor network (SMN, IC3), dorsal attention network (DAN, IC4), language network (LN, IC5), salience network (SN, IC6) and visual network (VN, IC7), which were consistent with previous researches.

Fig. 3: Independent components (ICs) in resting-state fMRI from different populations.
figure 3

a The IC analysis (ICA) of healthy individuals with ages older than 18 years (n = 10), identified seven spatial maps of intrinsic resting-state networks. b The correlation between IC similarity and age in seven populations (nHealthy = 203, nAD = 113, nDD = 57, nADHD = 406, nASD = 66, nCELF = 298, nLD = 73). The spider plots show the correlation coefficient between the individual spatial similarity of each IC and age. c The correlation between IC kurtosis and the age in seven populations. The spider plots show the correlation coefficient between the individual kurtosis of each IC and age. AD: anxiety disorder; DD: depression disorder; ADHD: attention deficit hyperactivity disorder; ASD: autism spectrum disorder; CELF: below clinical evaluation of language fundamentals criterion; LD: learning disorder. *p < 0.05, **p < 0.01 and ***p < 0.001.

For each individual, we performed subject-level ICA and calculated the similarity (the spatial similarity between a given IC and the HPC-ICA network template) and kurtosis (the spatial variability and independent decomposability of a given IC) of each IC to investigate whether the two spatial properties of the 7 ICs varied with age. In healthy individuals (Fig. 3b, c), both the similarity and the kurtosis of LN and VN were positively correlated with age, which indicates that the spatial stability (higher spatial similarity and decomposability) of sensory networks would increase along with age. We also found the spatial patterns of FPN, DMN and SMN become increasedly similar to those of healthy adults from children to adolescence, and age-related raises of kurtosis in SN. Combining the results of similarity and kurtosis from the six disease populations (Fig. 3b, c), we observed that the individuals with anxiety and ASD showed an age-related increase of similarity and kurtosis in DMN, SMN, LN, SN, and VN. The individuals with ADHD showed an age-related increase of similarity and kurtosis in FPN, DMN, SMN, LN, SN, and VN. The individuals with depression only exhibited a positive association between these two spatial properties and age in FPN, while the individuals with LD only exhibited similarity growth in SMN during development. However, possibly because the population with CELF also included a portion of anxiety, depression, ADHD, ASD, and LD individuals, their spatial similarity and kurtosis were positively correlated with age in all networks.

We then performed dynamic ICA (dyn-ICA) to explore the different modulations of functional connectivity in the seven ICs over time. Determined by elbow criterion, we estimated the first three connectivity matrices of healthy individuals older than 18 years, which represented a measure of covaried changes between each pair of brain regions across time. The three connectivity matrices were defined as dynamic states. We can see clearly that the modulations of functional connectivity appeared as IC-to-IC correlation, rather than simply region-to-region correlation (Fig. 4a, left). In our measurements, dynamic state 1 was characterized by stronger coupling between VN and SMN/SN/LN, between SN and SMN; dynamic state 2 was characterized by stronger coupling between SN and DMN/SMN/DAN/FPN/LN, between DAN and FPN/LN, between SMN and FPN/LN; the dynamic state 3 was characterized by stronger coupling between VN and SMN/DAN/FPN/LN.

Fig. 4: Dynamic states in resting-state fMRI from different populations.
figure 4

a The dynamic functional connectivity states averaged from healthy individuals with ages older than 18 years (n = 10). Left, the heat maps show the connectivity scores of paired brain regions in the three states. Right, the box-plots show the probability (blue) and variability (red) of the three states, which calculated between the ages of 5 and 21 in each population (nHealthy = 203, nAD = 113, nDD = 57, nADHD = 406, nASD = 66, nCELF = 298, nLD = 73). The two-sample t tests (two-sided) were conducted between the healthy population and the other six populations, respectively. Boxes represent interquartile range (IQR), central lines indicate the median, whiskers indicate 1.5 × IQR, notches indicate median ± (1.57 × IQR)/sqrt(n) and dot symbols indicate outliers. (b) The correlation between the parameters (probability and variability) of the three dynamic states and the age in seven populations. Dot colors represent r-values and dot sizes represent p-values. AD: anxiety disorder; DD: depression disorder; ADHD: attention deficit hyperactivity disorder; ASD: autism spectrum disorder; CELF: below clinical evaluation of language fundamentals criterion; LD: learning disorder. *p < 0.05, **p < 0.01 and ***p < 0.001.

We first quantified the probability (the possibility of a given dynamic state) and variability (the temporal variability of a given dynamic state) of each dynamic state, and compared the dynamic states of healthy individuals with the six disease populations in the age range of 5 to 21 years (Fig. 4a, right). The two-sample t test found that the individuals with ADHD (p = 0.003), ASD (p = 0.011), CELF (p = 0.005), and LD (p = 0.011) had a lower probability of dynamic state 1. Whereas the individuals with ADHD had a higher probability (p = 0.0498) of dynamic state 2. The higher variabilities of dynamic state 2 (pADHD = 0.003; pCELF = 0.01) and 3 (pADHD = 0.008; pCELF = 0.045) can also be seen in the individuals with ADHD and CELF. Moving to the specific age stage, we found that the differences in dynamic states between healthy individuals and disease population were more pronounced in childhood and early adolescence (Supplementary Fig. 3). We next used Pearson’s correlation to observe that the increased probability of dynamic state 1 matched the increasing age in individuals with anxiety (r = 0.29, p = 0.002), depression (r = 0.51, p = 5.2 10−5), ADHD (r = 0.16, p = 0.001) and CELF (r = 0.19, p = 8.9 10−4) (Fig. 4b). However, the probability of dynamic state 3 negatively correlated with the age of individuals with depression (r = −0.35, p = 0.007), ADHD (r = −0.11, p = 0.022) and CELF (r = −0.12, p = 0.045). Furthermore, the variability of the three dynamic states decreased with the increase of age in the healthy, ADHD, CELF, and LD populations. These results indicate that the variability of IC-to-IC modulations may decrease along with development, which strengthens the coupling/interaction between the sensory network and the higher-level network.

Age prediction and individual diagnosis based on multimodality brain network

To better verify whether the intrinsic activity of the brain could help us to identify mental disorders at specific ages, we trained various support vector machine (SVM) classifiers with different feature combinations of EEG and fMRI parameters. According to the results that had significant correlations with age in all populations, the following 23 parameters were used for feature combinations with different numbers of features: durations and occurrences of Map AP and LR (4 parameters: DurationAP, DurationLR, OccurrenceAP, OccurrenceLR), similarity and kurtosis of ICs 1-7 (14 parameters: ICS_1-7, ICK_1-7), probability of dynamic states 1 and 3 (2 parameters: Probability_1/3) and variability of dynamic states 1-3 (3 parameters: Variability_1-3). To avoid overfitting, only one feature combination having selected features was employed for each classifier (see Methods and Materials). We first tested the performance of various classifiers to identify a healthy individual’s age through brain activity. The age categories used here corresponded to four age stages, including childhood, early, middle and late adolescence. Figure 5a showed the accuracy of age classification using six feature combinations respectively, which were the best EEG parameter (duration of Map AP, accuracy: 39%), a combination of all EEG parameters (accuracy: 34%), the best fMRI parameter (any single fMRI parameter, accuracy: 25%), a combination of all fMRI parameters (accuracy: 35%), a combination of all EEG and fMRI parameters (accuracy: 40%) and the best combination of EEG and fMRI parameters (DurationAP, DurationLR, OccurrenceAP, ICK1/3/4/6/7, Probability1/3, Variability 2/3, accuracy: 78%). We found that relying on a single modality cannot effectively identify individual age; thus, it requires us to use the combination of multimodality data rationally. The confusion matrix in Fig. 5b has the best classification performance by using the best combination of EEG and fMRI parameters, which categorized child, early, middle, and late adolescent with an accuracy of 93%, 50%, 67%, and 100%, respectively. We found that the early adolescents were more prone to be classified as children (50%), while a small proportion of middle adolescents were classified as children and early adolescents. It is possibly due to the diversity and instability of ontogeny.

Fig. 5: Disease identification across ages.
figure 5

a The age classification accuracy of healthy individuals using multiple features derived from multimodality brain network. The colored bars indicate which parameter combination was used as the feature. b The confusion matrix of age classification within healthy individuals using the best combination of EEG and fMRI parameters. c The identification accuracy of individuals with six types of mental disorders at three ages (nAnxiety = 29/19/20, nDepression = 6/5/22, nADHD = 129/72/31, nASD = 15/6/11, nCELF = 81/47/33, nLD = 23/14/7). The colored bars indicate which stage of age was used for identification. On the horizontal axis, ‘EEG’/‘fMRI’ indicates the combination of all EEG/fMRI parameters was used as the classification feature, ‘all’ indicates the combination of all EEG and fMRI parameters was used as the classification feature, ‘best’ indicates the best combination of parameters, ‘comp’ indicates the same and compromised combination of parameters that used in the classification of the three age stages, which can obtain high accuracy at the same time. ADHD: attention deficit hyperactivity disorder; ASD: autism spectrum disorder; CELF: below clinical evaluation of language fundamentals criterion; LD: learning disorder.

We further tested if the parameters that can effectively identify ages in healthy populations can be generalized to categorize diseases at specific ages. Although the classification accuracy of the late adolescents was 100%, the sample size was relatively small (n = 4, see Supplementary Fig. 4), which ought to be insufficient for the classifier to distinguish healthy and disease individuals. Here, we identified the disease individuals from healthy individuals at the age of childhood, early and middle adolescence. In contrast, an indiscriminate combination of all parameters within- or cross-modalities of fMRI and EEG parameters do not reach satisfying identifiability. (Fig. 3c, black and gray).

The classification results showed that the best feature combinations for identifying individuals with various diseases were not the same, but all of them were a combination of a portion of the multimodality parameters from EEG and fMRI data (Supplementary Table 2). Except to identify the ADHD and ASD individuals at the age stage of childhood, the success rate of identifying individuals with various diseases at the three age stages was robust. In details (Fig. 3c, red), the identification accuracies at the age stages of childhood, early and middle adolescences in anxiety individuals were 79%, 86%, 91%; in depression individuals were 83%, 100%, 93%; in ADHD individuals were 50%, 76%, 93%; in ASD individuals were 50%, 100%, 100%; in CELF individuals were 65%, 81%, 91%; in LD individuals were 73%, 93%, 100%. In addition, we also attempted to identify a disease population at all three age stages using the same feature combination to yield relatively high accuracy, which we called a compromised combination (Fig. 3c, blue). As expected, all compromised combinations were composed of multimodality parameters (Supplementary Table 2). The identification accuracies of the six disease populations at three ages of childhood, early and middle adolescences were anxiety: 69%, 75%, and 78%; depression: 63%, 80%, 78%; ADHD: 50%, 62%, 77%; ASD: 50%, 81%, 89%; CELF: 61%, 71%, 79%; LD: 61%, 82%, 86%. In summary, the combination of parameters of the multimodality brain network using EEG and fMRI can help us better identify the age of the healthy individual and the disease of the individual at a specific age.

Discussion

The present study adopted resting-state EEG and fMRI datasets from multiple developmental stages, including children, adolescents, and adults, to delineate the spatiotemporal variation of brain networks during development. In particular, the global dynamic patterns of EEG microstates exhibit that during normative brain growth, along with the brain states becoming more active, the dominant networks shift from sensory networks to higher-level networks (i.e., attention and salience networks). The static and dynamic functional connectivity observed by fMRI suggests that with the increase of age, the individual functional network patterns become more similar to that of adults and tend to be invariable. Although a similar phenomenon was also seen in individuals with mental disorders, we demonstrate that the combinations of brain network properties derived from EEG and fMRI at rest had high accuracy for identifying the biological age in healthy individuals and diagnosis of mental health at specific ages. These results highlight that multimodality brain networks representing intrinsic functional organization are reliable in identifying the developing state of individuals and the disorders in different developmental stages.

Previous studies demonstrated that the EEG microstates, which reflect the instantaneous and simultaneous activity of large-scale networks, are useful in the examination of brain state or health, including assessing schizophrenia24,25, autism26,27, depression28, and disorder of consciousness22. Furthermore, the evaluation of EEG microstates is independent across centers for data collection24. One recent study showed that the duration and occurrence of microstates can help differentiate younger and older adults29, which suggests that microstate parameters may be sensitive to age. However, most researches focused on exploring the disease-related changes in an age group, and the studies about the age-related changes in microstates across developmental stages are very limited. In contrast, we have aggregated a large EEG dataset from individuals aged 5 to 44 years to depict the variation curve/trend of brain dynamics during development, which may correlate with the hierarchical development of cognitive function. We found that the dominance and activity of Map AP, which is related to higher-level cognition, increase from children to adolescents and decrease in middle-aged individuals; while Map LR, which is related to sensory network, contributes more to the early development and aging stage. These results are consistent with previous fMRI studies that the higher cognitive ability is related to the functional connectivity of executive network in younger adults but to that of the visual network in older adults13; and among various patterns of functional connectivity, the frontoparietal network (corresponds to Map AP) is the most distinctive in adults14. Although our study didn’t include a lifespan dataset, the change trend of duration, occurrence, and transition probability of microstates with age are consistent with the stable age of cerebral maturation10 and neuronal communication30.

Moreover, the age-related changes of dynamic parameters were also seen in population with mental disorders. In particular, the age-related increase of Map AP’s occurrence and decrease of Map LR’s duration were robust in populations with anxiety, depression, ADHD, ASD, CELF, which indicate that a higher occurrence of higher-level networks and a shorter duration of sensory networks may be crucial during development, regardless of disease. We also found that even though the differences of duration and occurrence of microstate were significant between healthy and disease group; the significance reduced when we focused on a specific age group. Therefore, we recommend that the age factor should not be ignored in the research on mental disorders, which may confuse disease-related differences with developmental changes.

Numerous promising fMRI studies have offered robust evidences that the intrinsic functional networks are reliable, age- and state-dependent31,32.The DMN, which is assumed as transmodal region and processes cognitive information, plays a significant role during development33. The connectivity strengthened from childhood to adolescence and the spatial pattern becomes similar to that in adults34. Consistent with previous studies, the spatial similarity of the DMN to the HPC-ICA network template increased along with age in healthy, anxiety35, ADHD36, ASD37,38, and CELF individuals. However, the evolution of functional networks is rarely discussed. Besides the DMN, the FPN, SMN, LN and VN in healthy individuals, which correspond to the primary-to-transmodal gradient of functional connectivity during development5, also had age-correlated raise in spatial similarities. In addition, the FPN and VN in ADHD36,39, the FPN, SMN and SN in ASD37,38, and the FPN and DMN in depression40, which are crucial as biomarkers in diagnosis, showed age-related changes by spatial similarity or kurtosis in our study. This doesn’t conflict with previous disease studies, the spatial evolution of functional networks may imply the progression of network forms and cognitive functions, while the abnormality in maturation of networks and in strength of connectivity are associated with disease.

We also examined the dynamic states of heathy individuals and six populations with mental disorders. We observed that the dynamic state 1, which is characterized by a stronger coupling between VN and SMN/SN/LN, between SN and SMN, has an increased probability along with age in anxiety, depression, ADHD, and CELF individuals. Oppositely, the dynamic state 3, which exhibits stronger coupling between VN and SMN/DAN/FPN/LN, showed a reduced probability along with age in depression, ADHD, and CELF individuals. These results imply that the dominance of between-network functional connectivity varies with brain development in specific populations. In contrast, the variability of all dynamic states negatively correlated with the age. Several prior studies have demonstrated similar declines of intrinsic fMRI activity in children and adolescents3, and with decreased modular dynamics, the large-scale brain network become progressive maturation41. It is worth mentioning that our EEG and fMRI results newly complement each other in time and space, to explain the characteristics of brain states at different ages. Along with the age-related increase of spatial similarity of functional network and reduction of variability of dynamic states, the increase of Map AP’s occurrence suggesting that the higher-level networks tend to be mature and become more active during development. In contrast, the fMRI results combined with decreasing duration of Map LR reveal that the spatial connectivity of the sensory networks stabilized with age, but the contribution of its activity declined.

Although there have been lots of studies using multimodality neuroimaging to improve brain-age prediction and cognitive diagnosis, the modalities in which were limited to MRI, such as structural MRI, fMRI and diffusion MRI15,42. Our study utilized both advantages from high temporal resolution in EEG and spatial resolution in fMRI to derive brain networks. Our results illustrated that the parameters of multimodality brain networks can yield higher accuracy of age classification than fMRI or EEG modality alone. It should be pointed out that given the interindividual heterogenicity of the nature of human brain development, our work on age classification is purposed to identify the developmental states of brain instead of to predict the true biological age in other studies. Similarly, when we used a single fMRI or EEG parameter to differentiate individuals with mental disorder from healthy individuals within a narrow age range, there was often no significant difference. However, by using the multimodality brain networks, the performance of individual diagnosis can reach above 90%.

In the identification of the same disorder population within each age stage, the best feature combinations are different across the three ages. However, some networks associated with specific diseases involved in all combinations, even in the compromised combination for the three age stages. For example, the duration of Map LR, DMN, SMN and SN were the most differentiable parameters in population with anxiety35,43. LN and dynamic state 1 played a role in identifying depression at all three ages44,45. In the population of ADHD, DMN, LN, SMN and dynamic state 2 were the most distinguishing46,47. Furthermore, we found that the strong coupling of the SN with DAN and FPN corresponded with the contribution of Map AP’s occurrence to the identification of ADHD in early and middle adolescence. For the identification of early and middle adolescents with ASD, the DMN, SMN, DAN, SN, VN and dynamic state 3 were the most distinguishable48,49. Lastly, to identify the individuals with LD at the three age stages, dynamic state 3 was the most distinctive, which is characterized by strong coupling between VN and SMN/DAN/FPN/LN. This is in line with the characteristics of LD population in this study, as we only included individuals with impairment in reading here. Overall, our results suggest that the temporal and spatial characteristics of brain networks may play different roles in age prediction and disease diagnosis. Combining the features of multimodality brain networks will help us achieve higher performance of age prediction and individual diagnosis.

In conclusion, this work revealed functional development of brain in both temporal and spatial domains. Adopting spatiotemporal multimodality by combining spatial functional networks and dynamic brain activities can help us make a more robust assessment of brain age and mental health.

Methods and materials

Participants

The dataset used in this study were obtained from the Child Mind Institute (CMI) Biobank50. The primary dataset of resting-state fMRI data and EEG data were from the Release 1.1, 4 and 9 of The Healthy Brain Network (HBN). After data quality check, we performed our analysis on the fMRI data from 991 subjects and the EEG data from 987 subjects. A second dataset of resting-state EEG data used to supplement adult data was selected from the Multimodal Resource for Studying Information Processing in the Developing Brain (MIPDB), which contains 30 healthy subjects (15 males, age 18–44 years).

According to the diagnosis data released from CMI, the fMRI data we used contained data from 203 healthy individuals (97 males, age 5–21 years), 113 patients with anxiety (67 males, age 5–20 years), 57 patients with depression (36 males, age 6–21 years), 406 patients with ADHD (115 males, age 5–21 years), 66 patients with ASD (12 males, age 5–19 years), and 73 patients with LD (31 males, age 6–21 years). The EEG data we used included 187 healthy individuals (91 males, age 5–44 years), 122 patients with anxiety (74 males, age 5–20 years), 53 patients with depression (36 males, age 8–21 years), 435 patients with ADHD (118 males, age 5–21 years), 87 patients with ASD (14 males, age 5–19 years), 68 patients with LD (26 males, age 5–20 years). We also used the clinical evaluation of language fundamentals (CELF) to assess the language disorder of individuals. The number of individuals that were below the CELF criterion was 298 of fMRI data (96 males, age 5–21 years), which included 24 anxiety, 14 depression, 136 ADHD, 25 ASD, and 26 LD patients; and 293 of EEG data (93 males, age 5-20 years), which included 28 anxiety, 8 depression, 134 ADHD, 31 ASD and 27 LD patients (for summary see Supplementary Table 1 and Supplementary Fig. 4).

Taken together, we obtained 548 individuals with both fMRI and EEG data, which involved 88 healthy individuals (42 males, age 5–21 years), 69 anxiety (40 males, age 5–20 years), 36 depression (23 males, age 8–21 years), 233 ADHD (68 males, age 5–21 years), 35 ASD (6 males, age 5–19 years), 45 LD patients (15 males, age 6–21 years), and 166 individuals with CELF below criterion (51 males, age 5–20 years, including 15 anxiety, 6 depression, 72 ADHD, 13 ASD and 18 LD) (for summary see Supplementary Table 1 and Supplementary Fig. 4).

Data acquisition information

All EEG data were collected using a 128-channal EEG recording system (geodesic hydrocel system by EGI). The EEG data were sampled at 500 Hz with a bandpass of 0.1 to 100 Hz. The recording reference was at Cz (vertex of the head). For each participant, head circumference was measured and an appropriately sized EEG net was selected. The impedance of each electrode was kept below 40 kΩ.

The MRI data from the Release 1.1 were collected on 1.5T Siemens Avanto. fMRI data were acquired using a multi-band gradient echo EPI sequence: TR/TE = 1450/40 ms, resolution = 2.5 2.5 2.5 mm3, flip angle = 55°, multi-band acceleration = 3, slice number = 54. A T1WI image (TR/TE/TI = 2730/1.64/1000 ms, flip angle = 7°, resolution = 1 1 1 mm3, slice number = 176) were acquired for registration. The MRI data from the Release 4 and 9 were collected on 3T Siemens Prisma. fMRI data were acquired using a multi-band gradient echo EPI sequence: TR/TE = 800/30 ms, resolution = 2.4 2.4 2.4 mm3, flip angle = 31°, multi-band acceleration = 6, slice number = 60. A T1WI image (TR/TE/TI = 2500/3.15/1060 ms, flip angle = 8°, resolution = 0.8 0.8 0.8 mm3, slice number = 224) were acquired for registration.

Data preprocessing

The fMRI data were preprocessed with MATLAB R2022a (MathWorks, Natick, MA, USA), Statistical Parametric Mapping (SPM12, http://www.fil.ion.ucl.ac.uk/spm) and the CONN-fMRI toolbox (version 22.a, https://www.nitrc.org/projects/conn) using the standard preprocessing procedure51. The first 4 scans in each functional run were removed, and the remaining scans were realigned to the fifth scan in the series. The series were slice-time corrected and the outlier detection was done for art-based identification of outlier scans for scrubbing. Then, the images were normalized to the Montreal Neurology Institute (MNI) space with isotropic voxels of 2 mm3. The normalized images were spatially smoothed using a 6-mm full-width at half maximum Gaussian kernel. Next, the structural image was segmented into white matter (WM), gray matter (GM) and cerebrospinal fluid (CSF), and normalized to the MNI space with isotropic voxels of 1 mm3. Finally, the functional data were denoised by the regression of potential confounding effects, including WM timeseries, CSF timeseries, head motion, outlier scans, linear trends within each functional run, and then followed by a bandpass filter of 0.01-0.1 Hz.

The EEG data with 128 electrodes were preprocessed using MATLAB and EEGLAB toolbox (version 2022.1, https://sccn.ucsd.edu/eeglab). The electrodes placed on the neck and cheeks were removed firstly and the remaining data were bandpass filtered between 0.2 and 40 Hz. The filtered data were semi-automatically inspected and the bad electrodes were interpolated before and after ICA. The ICA results were used to detect and remove blinks and eye movements. Next, the data were segmented into 2-s epochs, and the bad epochs were removed manually. Finally, the clean data were re-referenced, and then bandpass filtered to 2–20 Hz, 1–40 Hz, theta band (4–8 Hz), alpha band (8–12 Hz), beta band (12–25 Hz) and low gamma band (25–40 Hz) respectively.

Microstate analysis

The microstate analysis of EEG data was performed using MicrostateAnalysis (version 0.3, http://www.thomaskoenig.ch/index.php/software/microstates-in-eeglab/). For each filtered data of individuals, the EEG map topographies were computed at the global field power peaks and ignored the map polarity. The predominant microstate maps were identified using k-means clustering method. Four maps were selected as the optimal number of microstates, which had the highest cross-validation criterion when the global explained variance exceeded 85% (Supplementary Fig. 5). The optimal number of microstate maps was also consistent with previous researches21,22. The group-averaged maps of each frequency band, which were generated from healthy individuals with ages above 18 years, were defined as the template maps.

The individual microstate maps were quantified using the template maps and extracted temporal parameters for each of them. The following temporal parameters of each map generated from each frequency band were calculated: (1) the probability that indicates the dominance of each map, (2) the mean duration that indicates how long a given map remains stable, (3) the mean occurrence that indicates how many times a given map occurs in 1 s, (4) the mean transition probability that indicates the possibility a given map transit to any other microstate map. According to the spatial characteristics of the four microstate maps, we further averaged the template maps into two following maps: the Map AP, which was generated by averaging template maps ‘A’ that exhibits an anterior-posterior orientation and ‘B’ that exhibits a frontal-central maximum; the Map LR, which was generated by averaging template maps ‘C’ that exhibits a right-left orientation and ‘D’ that exhibits a left-right orientation. A probability-weighted spatial correlation difference, ΔCρ, was calculated to indicate which of the Map AP and LR is more dominant in an individual. The spatial correlation was defined by the Pearson’s correlation, and the difference was calculated as follows:

$$\Delta C=\,\frac{{\sum }_{i}^{n}\left({{{\boldsymbol{M}}}}_{i}\cdot {{{\boldsymbol{T}}}}_{{AP},i}\right)}{\sqrt{{\sum }_{i}^{n}{{{\boldsymbol{M}}}}_{i}^{2}}\cdot \sqrt{{\sum }_{i}^{n}{{{\boldsymbol{T}}}}_{{AP},i}^{2}}}-\frac{{\sum }_{i}^{n}\left({{{\boldsymbol{M}}}}_{i}\cdot {{{\boldsymbol{T}}}}_{{LR},i}\right)}{\sqrt{{\sum }_{i}^{n}{{{\boldsymbol{M}}}}_{i}^{2}}\cdot \sqrt{{\sum }_{i}^{n}{{{\boldsymbol{T}}}}_{{LR},i}^{2}}}$$

ΔC is the spatial correlation difference of the two template maps, n is the number of electrodes, i is the electrode i, M is the measured voltage of individual map, TAP is the measured voltage of Map AP and TLR is the measured voltage of Map LR. Accordingly, the probability-weighted spatial correlation difference was calculated as follows:

$$\Delta {{{\boldsymbol{C}}}}_{\rho }=\mathop{\sum }_{j=1}^{4}\Delta {{{\boldsymbol{C}}}}_{j}\cdot {\rho }_{j}$$

where ρ is the probability of a given map, and j indicates the map j.

Independent component analysis

The group spatial ICA52 of preprocessed fMRI data was performed using CONN-fMRI toolbox. First, a singular value decomposition (SVD) with 64 components was used on fMRI data for each subject as a subject-specific dimensionality reduction step. Second, the dimensionality of the data was further reduced using a group-level SVD with 20 components, which represent temporally coherent functional networks. And a fast-ICA algorithm was used to identify spatially independent group-level networks from the resulting components. Last, a back-projection approach (GICA3) was used to obtain ICA maps for each individual subject. The spatial correlation values between estimated ICs and the functional network templates were used for IC selection. Based on the functional network templates (the HPC-ICA network template), seven ICs were identified, including frontal-parietal network, default mode network, sensorimotor network, dorsal attention network, language network, salience network and visual network. The same IC selection procedure was performed for group-level ICA that to identify seven ICs based on healthy individuals older than 18 years, and for subject-level ICA that to assess the functional networks of each individual. Then, the spatial parameters of the seven subject-specific ICs were calculated: (1) the similarity that indicates Pearson’s correlation between a given IC and its corresponding template, (2) the kurtosis that indicates the spatial variability of a given IC, and the kurtosis was calculated as follows:

$$K=\,\frac{1}{n}\mathop{\sum }_{i=1}^{n}\left[{\left(\frac{{B}_{i}-\mu }{\sigma }\right)}^{4}\right]$$

K is the kurtosis of a given IC, B is a set of voxel values from a given IC volume (3D image), μ is the mean value of all voxels, σ is the standard deviation of all voxels, n is the number of voxels, i is the voxel i.

Dynamic independent component analysis

The dynamic variability of functional connectivity was measured by the dyn-ICA51 using CONN-fMRI toolbox. The dyn-ICA estimated the temporal modulation factors characterizing the dynamic changes in functional connectivity between each pair of regions of interest (ROIs) over time. The ROIs were defined by 32 HPC-ICA network ROIs (provided by CONN-fMRI toolbox). We first used the fMRI data from healthy individuals with ages above 18 years to estimate 1-20 factors using dyn-ICA with a 16-s smoothing kernel. The elbow criterion was used to determine that three factors are the optimal number of factors. Then, we estimated the first 3 temporal modulation factors/connectivity matrices of each individual with the 16-s smoothing kernel and defined them as dynamic states. The temporal parameters of the three subject-level dynamic states were calculated: (1) the probability that indicates the possibility of a given dynamic state, (2) the variability that indicates the temporal variability of a given dynamic state, which was calculated as the temporal component time-series standard deviation.

Identification analysis

To ensure the effect of EEG and fMRI parameters in the identification analysis, we only used the data from individuals that have both EEG and fMRI data (for details, see ‘Participant’ section above, Supplementary Table 1 and Supplementary Fig. 4). We first used the classification analysis to identify the age stages of healthy individuals. The four age stages were childhood (5-9 years), early adolescence (10-13 years), middle adolescence (14-17 years), late adolescence (18-21 years)53. According to the significant correlation results between EEG/fMRI parameters and ages, we selected 23 parameters as features, including 4 EEG parameters (the durations and occurrences of Map AP and LR), 14 ICA parameters of fMRI (the similarities and kurtoses of ICs 1-7), and 5 dyn-ICA parameters of fMRI (the probabilities of dynamic states 1 and 3, the variabilities of dynamic states 1-3). Considering the selection and combination of different numbers of features, there were \({\sum }_{n=1}^{23}{C}_{23}^{n}=\,\)8388607 possible feature combinations produced by 23 features. Because support vector machine (SVM) can get better results than other algorithms on small sample training sets, we selected it for the identification analysis. To avoid overfitting, only one out of 8388607 feature combinations was used to train a four-class SVM classifier. For each classifier, only those selected features (number ≤ 23) of one feature combination were input into the SVM classifier. Thus, we totally needed to train 8388607 classifiers. All steps were cross-validated (leave-one-subject-out). We then searched for the classifier with the highest accuracy for age identification of healthy individuals, and defined the feature combination it used as the best feature combination. By using the features selected in the best feature combination we determined the classifier model.

Considering that the age-related changes of features occurred in all seven populations, the discrimination between healthy individuals and a disease population at certain ages should be smaller. Therefore, we trained two-class SVM classifiers to identify patients with a specific disorder from healthy individuals at a given age stage. Likewise, each time we only applied one feature combination to one classifier. For example, we trained a two-class SVM classifier using limited features from one kind of feature combination to identify healthy individuals and patients with anxiety disorder in early adolescence. In total feature combinations, the best one was determined by the highest accuracy. The SVM classifier that using the best feature combination was determined as the final classifier model.

Finally, we used two methods to assess the reliability and stability of the classifier model that used the best feature combination. For the first method of model assessment, we used N-fold method to compare the results of classification that used the feature combination of all EEG and fMRI parameters (referred as “all” below) with those used the best feature combination. Considering the sample size, N would be 3, 4 and 5. For each N-fold analysis, we randomly selected (N-1)/N data as the training data, and the remaining data as testing data. The sampling process was repeated 100 times, and each time generated a classification accuracy. Two-sample t-tests (two-sided) were conducted between the accuracies of classification that used “all” feature combination and those used the best feature combination. We can find that in the process of randomly sampling the training set, except to identify the ADHD and ASD individuals at the age stage of childhood, the best feature combination resulted in significantly better accuracy than “all” feature combination (Supplementary Fig. 6). These results demonstrate that the classifier using the best feature combination is relatively more reliable and stable than the classifier using “all” feature combination in case of the training data changes. For the second method of model assessment, we estimated the stability of classification in the face of increasingly incorrect training labels. For one type of classification that used the selected feature combination, we flipped the training labels with increasing percentages, which from 0% to 100% in steps of 10%. To avoid bias and impact of variability, we randomly flipped the training labels at each percentage, and repeated the process 2000 times. We can find that, except to identify the ADHD and ASD individuals at the age stage of childhood, by flipping the training labels, the classification collapsed and eventually yielded wrong results. However, when the proportion of correct training labels was not lower than the chance level (25% for age prediction, 50% for individual diagnosis), the accuracy of classifier using the best feature combination was always higher than those using “all” feature combination (Supplementary Fig. 7). These results demonstrate that the classifier using the best feature combination is relatively more robust than the classifier using “all” feature combination, and is more sensitive to the wrong training labels.

Statistics and reproducibility

For demographic characteristics of all individuals, we conducted a two-sample t test to examine the variances of age distribution between healthy and disease groups, and χ2-test to examine the frequency differences of sex (Supplementary Table 1).

To characterize the changes of microstate properties along with ages (from children to adults) in healthy individual, we performed a first-, second- and third-order polynomial model to fit the changes of ΔCρ, duration, occurrence and transition of Map AP and Map LR that generated from each frequency band with the age of 5 to 44 years. Because the sample size of subjects older than 22 years was relatively small, we used normalization to center and scale the data, which help to avoid overfitting. To reduce the influence of outliers, we used a robust regression with bisquare kernel function. The coefficient of determination (R2) was used to indicate the fitting performance. R2 < 0 indicates that the model has a worse ability to predict the data, R2 > 0 indicates that the model has a better ability to predict the data, R2 = 1 is an ideal model. We determined the final fitting model of each parameter from the first-, second-, and third-order polynomial models according to the highest R2. Since the 1–40 Hz band theoretically covered information from other frequency bands and it also had better fitting results, we chose the microstate parameters generated from 1–40 Hz to do further analyses.

The significance tests were applied to the microstate parameters and dyn-ICA parameters between healthy individuals and each disease population (healthy vs. anxiety, depression, ADHD, ASD, CELF, LD, respectively). Considering the significant frequency differences of sex between healthy and disease groups (Supplementary Table 1), the MANOVA were firstly applied to the microstate parameters and dyn-ICA parameters, to examine the interaction effect between sex and disease factors (Supplementary Table 3). According to the results of significant interaction effects between sex and disease factors, we conducted two-sided two-sample t-test using sex as regression factor on duration of Map LR between healthy and ADHD groups, and probability of dynamic state 1 between healthy and depression groups. For other parameters without significant interaction effect, simple two-sided two-sample t-tests were applied between healthy and disease groups. For durations and occurrences of Map AP and LR, which have large significant difference, we further applied the one-way ANOVA between healthy individuals at four age stages (4 stages: 5–9, 10–13, 14–17, 18–44 years) and seven populations at four age stages (4 stages of healthy: 5–9, 10–13, 14–17, 18–44 years; 4 stages of anxiety, depression, ADHD, ASD, CELF, LD: 5–9, 10–13, 14–17, 18–21 years). Because all groups with mental disorders were compared with healthy group, which could be seen as a control group, we used Dunnett correction for the multiple comparison. To explore the age changes of spatiotemporal parameters in six disease populations, Pearson’s correlations were observed between all fMRI/EEG parameters (including durations and occurrences of Map AP and LR, spatial ICA parameters, dyn-ICA parameters) and the age of 5–21 years in each population.

Reporting summary

Further information on research design is available in the Nature Portfolio Reporting Summary linked to this article.