Skip to content

OHBA-analysis/Tinda

Repository files navigation

# Temporal Interval Network Density Analysis (Tinda)

This repository contains the analysis code for the manuscript [Large-scale cortical networks are organized in structured cycles]<https://www.biorxiv.org/content/10.1101/2023.07.25.550338v2>. However, note that an improved API is implemented in the osl-dynamics toolbox (https://github.com/OHBA-analysis/osl-dynamics/blob/main/osl_dynamics/analysis/tinda.py).


## Installation
All analyses were run on Linux (Rocky Linux 8.10).
This code requires MATLAB, a licensed software (See MathWorks for installation instructions and license information). Analyses were run on version 2023a (9.14.0.2254940), and further requires a number of MATLAB licensed, and open-source toolboxes:
- Bioinformatics Toolbox                                Version 4.17 
- FastICA for Matlab 7.x and 6.x                        Version 2.5 
- Image Processing Toolbox                              Version 11.7
- Statistical Parametric Mapping                        Version 6906 
- Statistics and Machine Learning Toolbox               Version 12.5 
- OSL Matlab (https://github.com/OHBA-analysis/osl-core/tree/master)                                                   osl2019Nov04
- osl-ephys (https://github.com/OHBA-analysis/osl-ephys/) v0.10.0
- osl-dynamics (https://github.com/OHBA-analysis/osl-dynamics/) v1.2.10
- HMM-MAR (https://github.com/OHBA-analysis/HMM-MAR) commit 83788633fd00d62e0bbc0fa9cc814242df944e4f
- Colorbrewer (https://uk.mathworks.com/matlabcentral/fileexchange/45208-colorbrewer-attractive-and-distinctive-colormaps) v3.2.3
- Circular Statistics Toolbox (https://uk.mathworks.com/matlabcentral/fileexchange/10676-circular-statistics-toolbox-directional-statistics)    v1.21.0.0
- Intraclass Correlation Coefficient (ICC) (https://uk.mathworks.com/matlabcentral/fileexchange/22099-intraclass-correlation-coefficient-icc) v1.3.1.0
- APACE (https://github.com/NISOx-BDI/APACE) commit 6a2c5d444a828549ffcd7e541fc4760f4c4f1e33
- FSL v6.0.7.9
- MEGIN MaxFilter v2.2
- Higgins2020_Neuron (https://github.com/OHBA-analysis/Higgins2020_Neuron/tree/master) commit 8b3019b


## Manuscript pipeline
MEG data were preprocessed using OSL Matlab, osl-ephys, MNE-Python, SPM12, and FieldTrip Toolbox. Details can be found in the original publications (Higgins et al., 2021, Vidaurre et al., 2018, Quinn et al,. 2018), and in the 1.0_Preproc folder.
First-level Hidden Markov model for the MEGUK dataset and Replay dataset were trained as in Higgins et al., 2021. For the CamCAN dataset, 2.0_HMMfitting/CamCan_HMM.py was used. For the HCP dataset, 2.0_HMMfitting/HCP_hmm.m was used. The Wakeman-Henson dataset was trained as in Gohil et al., 2024. All second-level HMMs were fitted according to 2.0_HMMfitting/secondLevelHMMfit.m

All main analyses were run according to 3.0_SequenceAnalysis/SequenceAnalysis.m for studies [1,3,6,7]. Additional analyses and plotting scripts can be found in 2.0_HMMfitting/secondLevelHMMfit.m, 5.0_BehaviouralAnalysis/camcan_correlations.m, 5.0_BehaviouralAnalysis/HCP_correlations.m, 5.0_BehaviouralAnalysis/wakeman_henson_correlation.m, 5.0_BehaviouralAnalysis/replay_correlations.m, and figures/figure5.m

About

Temporal-Interval Network Density Analysis

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published