## 2 Materials and Methods
### Functional Connectivity Analysis  
Pre- and post-processing of functional and structural data was performed through the CONN toolbox [17], implemented in SPM (SPM 12, The Wellcome Centre for Human Neuroimaging, UCL Queen Square Institute of Neurology, London, UK) and MATLAB (R2021b (9.11), The MathWorks Inc., Natick, MA, USA) packages. The default pre-processing for all patients included: functional realignment and estimation of motion parameters; slice-timing correction; outlier detection and head motion correction; direct normalization of functional and structural data to MNI space plus segmentation of all data to gray matter, white matter and cerebrospinal fluid; functional smoothing with a full-width-half-maximum (FWHM) of 6 mm; denoising with linear regression and temporal band pass filtering between 0.01 and 0.1 Hz; detrending. For denoising, CSF and WM nuisance regression were also included. The co-registered anatomical and functional images in MNI space were parcellated into 136 regions of interest (ROI) (136 parcels) using automated anatomical labeling--AAL atlas (the default atlas of CONN toolbox). All co-registered anatomical and functional images were inspected for the transformation of the tumor area to MNI space to ensure correct anatomical parcellation via the atlas. All the steps of our pipeline were monitored by two board-certified neuroradiologists to confirm the correct transformation to the standard space, correct segmentations and correct ROI fitting. Any necessary adjustments were carried out before proceeding to the following steps. A summary of the pipeline used for this study is presented in Figure 1.  
Finally, the average timeseries within each ROI were estimated. ROI-to-ROI connectivity matrices represent the connectivity between one of the 136 ROIs to the remaining ROIs. These matrices show the degree of functional connectivity between each pair of ROIs, with each element defined as the Fisher-transformed bivariate correlation coefficient between a pair of ROIs BOLD timeseries [17]. ROI-to-ROI connectivity matrices were obtained for three conditions of whole-brain ROIs, only left and only right hemisphere ROIs for each HGG, LGG and HC group. Graph theory analyses on each ROI-to-ROI matrix were conducted using the Louvain Algorithm in CONN toolbox. All ROI-level graph measures are based on nondirectional graphs with nodes (ROIs) and edges (supra-threshold connections). For each patient, a threshold of z > 2 and \(p\) < 0.05 was set to compute a graph adjacency matrix by thresholding the associated ROI-to-ROI matrix. From the resulting graphs, we then computed graph-theoretical measures to address the topological properties of each ROI within the graph, as well as of the entire network of ROIs [14]. Seven graph-theoretical metrics were calculated applying two-sided FDR correction (\(p\) < 0.05): global/local efficiency (representing the global and local connectivity of each ROI), betweenness centrality (showing the ratio of a time that a node is part of the shortest path between any two pairs of nodes in a graph), cost (proportion of edges from a node), average path length (the shortest distance between the current node and all other nodes), clustering coefficient (ratio of connected nodes to all neighboring nodes) and degree (the number of nodes to which the selected node was connected). A detailed description of these metrics is available elsewhere [14] and summarized in Supplementary Table S1. We used the above graph-theoretical metrics to evaluate the connectedness and integration of every node in the regional (local) and global networks. We considered the small-worldness of functional graphs to be the combination of high local clustering and short path length as well as high global/local efficiency and low cost [14].