/myspm

Custom MATLAB scripts for clicking-free SPM analysis

Primary LanguageMATLAB

myspm

This repo is no longer maintained. Please see: https://github.com/seunggookim/NCML-code

SPM (Statistical Parametric Mapping; www.fil.ion.ucl.ac.uk/spm/) is a well-known MATLAB toolbox for neuroimaging analysis. Most of analyses are programable using the MATLAB batch editor including generating result reports with tables (“Results Report”).

But plotting orthogonal sections of suprathreshold clusters on the top of a structural image is not available from the MATLAB batch editor. When you have many models and contrasts to test, exploring all different models and contrasts require A TONS of mouse clicking, which might cause carpal tunnel syndrome.

In order to protect the wrists of such neuroimaging researchers (or just for lazy guys like me), one can use MATLAB functions here that generate orthogonal sections at each local maximum using ‘xSPM’, ‘hReg’, and ‘TabDat’ variables (which are generated by the "Results Report" module) as well as SPM's functions such as ‘spm_sections.m’ and ‘spm_orthviews.m’ functions.

  • myspm_fmriglm.m performs statistical inference on 4-D data (e.g., fMRI) using SPM's 1st-level GLM modules.
  • myspm_glm.m performs statistical inference on 3-D data (e.g., fMRI contrast, gray matter density, Jacobian determinant) using SPM's (2nd-level) GLM modules.
  • myspm_results.m generates results reports of maximal intensity projection (MIP or 'glass brain') and orthogonal slices view and a scatter plot for each suprathreshold cluster, also creates a summary table with peak value, cluster size, voxel/cluster-level corrected p-values, coordinates, and structure names of the peak and the cluster.
  • myspm_graph.m creates a scatter plot and a linear regression line.
  • myfsl_atlasquery.m returns the probablistic atals information of a given MNI coordiante using Harvard-Oxford cortical/subcortical atlases, cerebellar atlas, and JHU-ICBM DTI atlas included in FSL ($FSLDIR required to be valid).
  • myspm_NMatlas.m returns structure names from [spm12]/tpm/labels_Neuromorphometrics[.xml|.nii], which is derived from the "MICCAI 2012 Grand Challenge and Workshop on Multi-Atlas Labeling" (https://masi.vuse.vanderbilt.edu/workshop2012/index.php/Challenge_Details). These data were released under the Creative Commons Attribution-NonCommercial (CC BY-NC) with no end date. Users should credit the MRI scans as originating from the OASIS project (http://www.oasis-brains.org/) and the labeled data as "provided by Neuromorphometrics, Inc. (http://Neuromorphometrics.com/) under academic subscription". These references should be included in all workshop and final publications.

Please note that the other functions not noted above are still 'in development'. You may not want to use half-made functions and/or to read through the chaotic codes ;) TODO: this should work without other things than MATLAB and SPM12.