-
Notifications
You must be signed in to change notification settings - Fork 8
Permutation based Cluster Correction
Zarrar Shehzad edited this page May 5, 2017
·
2 revisions
You can check out the two needed scripts on this page: https://gist.github.com/czarrar/0e620cf64a975380cdc2. You can run as follows (the script works with either ROI-based or voxel-based data). You need to make sure that when running connectir_mdmr.R
, you use the --save-perms options as the permuted results are used for the cluster correction.
./le_correcter.R ${distance_directory} ${mdmr_directory}
- Where distance_directory is the full path to the subject distances directory and mdmr_directory is the full path to the MDMR directory.
- This will create a new directory called cluster_correct_v05_c05 (voxel level threshold of p < 0.05 and cluster level threshold of p < 0.05) within the mdmr directory you input.
- This directory will have a clust_logp_X.nii.gz file that is the thresholded -logp file with clusters corrected based on a permutation test. There is also an easythresh directory that runs everything with easythresh as well. It will run easythresh first since it is very fast. In both permutation and easythresh outputs, the voxel values represent significance estimates from permutation testing.
- If you want to change the voxel or cluster thresholds you need to look for
vox.thresh
orclust.thresh
in the le_correcter.R script and change it.
For now, the way this will do cluster-correction for ROIs is save that output into voxelwise space and then determine the clusters. I'm working on the more direct approach of calculating the clusters from the ROI data but that's not yet ready.