Abstract

In the TDApplied package vignette “TDApplied Theory and Practice” simulated data is used to provide examples of package function. In this vignette we will demonstrate that TDApplied can carry out meaningful analyses of real (i.e. non-simulated) data which other software packages cannot. We analyzed data from a very well-known neurological dataset, and identified topological features of neurological computation in single and multiple subjects which were correlated with (i) the task the subjects were performing while the data was collected, and (ii) the behavior (i.e. reaction time) of the subjects during the task – these correlations suggest that the features are meaningful in the context of an neuroimaging analysis. Moreover, these features were identified, interpreted and analyzed with the bootstrap_persistence_diagram, vr_graphs and diagram_kpca functions, only the first of which has any implementation in another R package (TDA). TDApplied is therefore a powerful tool for applied topological analyses of data.

Introduction

A popular technology for studying neural function is called functional magnetic resonance imaging (fMRI), in which oxygenated blood-flow across the brain is detected via magnetic resonance over multiple time points; fMRI is a proxy measurement of neural activity. Spatial activity patterns, i.e. vectors of measured values across space in a single time point, are modulated by performing tasks. The study design is the sequence of temporal blocks of performing these tasks and each task type is called a condition, and a study design can evoke meaningful information about neural processing related to tasks. Collections of spatial activity patterns (for example the spatial patterns evoked by a particular task over multiple time points) have previously been analyzed with topological and geometric techniques which capture their global structural features (J. Shine 2019; Saggar et al. 2018, 2021; X. Liu, Chang, and Duyn 2013). However, these analyses are not designed to capture the spatially periodic features of fMRI data which we would expect to exist in abundance (Greve et al. 2013; T. Liu 2016; Caballero-Gaudes and Reynolds 2017). One persistent homology analysis of fMRI spatial pattern data found robust 0-dimensional topological features (i.e. clusters of time points with similar spatial patterns) whose persistence values negatively correlated with fluid intelligence (Anderson et al. 2018). Larger differences between spatial patterns at different time points generally corresponded to lower values of fluid intelligence, but higher-dimensional topological features such as loops were not considered in that analysis.

In this exploratory analysis, using the R package TDApplied, we utilized persistent homology to find, in one subject’s fMRI data in an emotion task, task-related signal in the form of a spatial loop. We then linked the loop back to the subject’s raw data to interpret what neurological features the loop represented. Finally we showed that topological features in 100 subject’s emotion task fMRI data were correlated with behavior (i.e. the subject’s response time to certain task blocks). While neuroimaging researchers would not consider a single loop within one subject “real” or “significant” without finding a similar loop across multiple subjects, the task of optimally matching loops between datasets is an open problem, so we leave the problem of finding group-level spatial loops to future work. For our analysis we will use data from the famous Human Connectome Project (M. Glasser 2016b) which contains extensively preprocessed neuroimaging data from roughly 1200 subjects. We focused on the HCP emotion task data, which alternated between two conditions - deciding which of two faces matched another target face in emotion, and deciding which of two shapes matched another target shape. We only analyzed the right-to-left phase encoding scan (this is a parameter of MRI imaging which determines the ordering of when image slices of the brain are obtained) as this was the phase encoding direction for the specific subject loop we analyzed. Also, all fMRI data was projected onto surface nodes – points on a mesh of the brain’s surface geometry – which are more comparable across subjects than standard 3D volumes (M. Glasser 2016b). The script used to perform the analysis can be found in the exec directory of TDApplied. Our analysis demonstrates the potential of using TDApplied for deriving interpretable and otherwise obscured insights from real datasets.