TUTORIAL FOR PREPROCESSING A. task-fMRI preprocessing Requires: -MATLAB -SPM -Group-ICA ************************************************* ------------------ 1. Download ------------------ ************************************************* Download fMRI sequences from https://openneuro.org/datasets/ds004144/versions/1.0.2 Download scripts from https://zenodo.org/record/6617778#.Yp6R53ZBw2w (preprocessing.rar) ************************************************* ------------------ 2. Unzip --------------------- ************************************************* 1. Copy into bids_uz 2. Open terminal in bids_uz 3. Unzip anatomical ---> gunzip sub-xx/ses-1/anat/*.nii.gz 4. Unzip functional ---> gunzip sub-xx/ses-1/func/*.nii.gz ************************************************* --------------- 3. Reorientation ---------------- ************************************************* To reorient T1 and task-fMRI sequences: 1. Open sequence to reorient on SPM fmri 2. Select "Display" and open the sequence to be reoriented 3. Reorient it according to anterior commisure 4. Adjust rotation (pitch, roll, yaw -0.01 scale-) 5. Write parameters of orientation (as guide for the other sequences) 6. Select "Set origin" 7. Select "Reorient" 8. Select the sequence (for functional, select all volumes -0:999-) 9. Accept and save reorientation map * Corresponding files are: T1: sub-xxx/anat/sub-xxx_T1w.nii Task: sub-xxx/func/sub-xxx_task-rest_bold.nii ************************************************* ----------- 4. Slice Time Correction ------------ ************************************************* For the reorientated fMRI-task sequences: 1. In SPM fmri select "Slice timing" 2. Load bids/derivatives/prep/stc.mat Parameters specified: -Number of slices: 37 - TR: 2 - TA: 1.94594594594595 **TR-(TR/nslices)** - Slice order: 1x37 double **interleaved button-up** - Reference slice: 19 - Filename prefix: a 3. Specify "Data" --> "Session" 4. Unselect all files 5. Select all volumes from the sequence (1:999) 6. Run 7. Review ************************************************* ---------------- 5. Realigment ------------------ ************************************************* 1. Run in matlab run_realignment_estimate_reslice_TB_190704.m 2. Review Parameters: (default) - Estimate and write - quality 0.9 - sep 4 - fwhm 5 - rtm 0 - interp 4 - wrap [0 0 0] - mask 1 ************************************************* ------------- 8. Corregistration ---------------- ************************************************* 1. Run in matlab run_coregistration_estimate_TB_190712.m 2. Review histogram and T1 ovaerlaying functional *Open SPM to obtain histograms Parameters:(default) - Estimate - Cost_fun nmi - sep [4,2] - fwhm [7,7] ************************************************* -------------- 9. Normalization ----------------- ************************************************* a) Functional 1. Run in matlab run_normalization_TB_190716.m 2. Review Parameters: - estimate & write - biasreg 1e-04 - biasfxhm 60 - affreg mni - reg[0,1.000000000000000e-03,0.500000000000000,0.050000000000000,0.200000000000000] - fwhm 0 - samp 3 - bb [-78,-112,-70;78,76,85] - vox [3,3,3] - interp 7 - prefix w b) Structural 1. Open in SPM "Normalise-write) 2. Specify: - Subject-> Deformation field: "y" anatomical sequence - Subject-> Images to write: T1 - Voxel sizesL: [1 1 1] 3. Review *Remeber to deselect the sequences before selecting the new one for each subject ************************************************* ---------------- 9. Smoothing ------------------- ************************************************* 1. Run in matlab run_smoothing_TB.m 2. Review Parameters: - fwhm [6,6,6] - prefix s ************************************************* ------- 10. Movement parameters plot ------------ ************************************************* 1. Run in matlab create_realignment_plots.m 2. Review ************************************************* ------------- 11. Artifact remotion ------------- ************************************************* Run the GUI for Group-ICA. For each subject select extraction of 100 independent components using the Infomax algorithm and ICASSO to ensure the stability of components. Then visualize each component and do a manual selection of components to keep. ************************************************* ----------- 12. First level design -------------- ************************************************* 1. Run in matlab run_firstlevels_TB_161019.m This script needs firstlevel_job_TB_061219.mat Parameters: - High pass filter: 192 (or 128) - derivatives [1,1] (time and dispersion derivatives) * To save the plot, run one by one and save in /bids/derivatives/l1/mtrx with mtrx_xx.jpg as filename * For subject 08 (#5), adjust tasklenght (line 23) to 774 ************************************************* ************************************************* B. task-fMRI preprocessing Requires: -CONN Toolbox 1. Upload the functional and anatomical sequences to CONN 2. After setting up, a preprocessing pipeline (it can be a predefined pipeline from the menu or following the steps mentioned for the task-fMRI sequences) 3. Set ART thresholds to > 0.9 mm for head motion, and 5 for for global signal Z score 4. Run denoising