Export mass-univariate neuroimaging results computed in SPM as NIDM-Results packs.
A NIDM-Results pack is a compressed file containing a NIDM-Results serialization and some or all of the referenced image data files in compliance with NIDM-Results specification.
-
In Matlab, open
SPM
spm fmri
-
Open the
Batch Editor
by clicking on theBatch
button in the SPM12Menu
window -
Open the menu
SPM
>Stats
>Results Report
(Fig. 1.) -
In the batch window (Fig. 2.)
- Fill in information about the results you are interested in (in particular
SPM.mat
file, contrast number, threshold, etc.) - In
Export results
, selectedNew: NIDM (Neuroimaging Data Model)
- Fill in information about your analysis (
Modality
,Reference space
,Groups
etc.``)
Fig. 1. Results report | Fig. 2. NIDM export |
- The latest version of the NIDM exporter in available in the last SPM release (v. xx)
Test data is available at https://github.com/incf-nidash/nidmresults-examples/, you will need a local copy of this repository stored with git lfs:
cd test/data
git clone https://github.com/incf-nidash/nidmresults-examples.git
git lfs install
To run the tests, you will need to install docker.
Then from the top folder of this repository, run:
did=$(docker run -it -d --rm -v `pwd`/test:/test -v `pwd`/exporter:/exporter cmaumet/octave-spm)
docker exec -it $did octave --no-window-system --eval "addpath('/exporter'); addpath('/test'); nidm_export_all('/test/data/nidmresults-examples', '/test/spmexport')"
python test/TestSPMResultDataModel.py