Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: remove possibly compromised link


I (Our primary recommendation, formerly option C). A new CIFTI library has been written for matlab, which is backwards compatible with ciftiopen, etc from option II, but provides the full CIFTI XML header information similar to how it is stored in the file (which encodes what each CIFTI index represents), and helper functions to extract or replace data for a specific structure.  There are no external dependencies when reading CIFTI-2 files, which should cover all HCP CIFTI files in virtually all data releases.  To read CIFTI-1 files with this code, install Connectome Workbench v1.0 or newer, available here.  This library is available at


II (formerly option B). Using Workbench v1.0 or newer + GIFTI toolbox code (descriptions below). This method has the limitation of not telling you what the CIFTI indices represent (what vertex or voxel, etc) and it creates intermediate files (that are deleted as part of the provided code). For this approach you need a couple of prerequisites:


2) A matlab set of functions called the GIFTI toolbox by Guillaume Flandin (httphttps://wwwgithub.artefact.tkcom/softwaregllmflndn/matlab/gifti/)

Here are MATLAB functions to download and use for importing CIFTI files (e.g., *.dtseries.nii) using these prerequisite tools: