Hi Doug,
Sorry, the ${s} was typo, and the ${h} was for hemisphere, but I modified the commands below to make them more straight forward.
With the first command I am running mris_preproc with multiple controls and one patient together and then running mri_surf2surf to do smoothing, and mri_glmfit with the fsgd and mtx files displayed below. In the second command I am running mris_preproc and mri_surf2surf on the control group and patient separately. Then I use mri_concat to get the mean and sd from the control group, which I compare to the patient file using fscalc.fsl to generate the zmap. I attached a screen shot from one subject to show how different the results are (fscalc method is the one with the large negative cluster in the prefrontal). The results of the fscalc.fsl method seem to be correct, but I am not sure why they differ so much.
So my question is, if I use the fscalc.fsl method, is there a way to do the monte carlo based cluster correction? Alternatively, is there something wrong with the way I am running mri_glmfit that it is not running a z-test?
Thanks again, Jonathan
[image: Inline image 2][image: Inline image 1]
------------------------------
Message: 21 Date: Tue, 05 Nov 2013 18:26:14 -0500 From: Douglas N Greve greve@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] z-test differences from fscalc and mri_glmfit To: freesurfer@nmr.mgh.harvard.edu Message-ID: 52797E96.704@nmr.mgh.harvard.edu Content-Type: text/plain; charset=ISO-8859-1; format=flowed
When you say that you are getting very different results, what are you comparing exactly? I can't tell what your mri_glmfit command is because it is embedded in a script with lots of variables. Have mercy on me and just give me a simple command line that I don't have to struggle with:) doug
On 11/05/2013 02:21 PM, Jonathan DuBois wrote:
Hi All,
In a previous post Doug suggested two methods for generating voxel-wise z-score maps, one using glmfit with one subject in one group and the second using fscalc.fsl. Link to post:
https://mail.nmr.mgh.harvard.edu/pipermail//freesurfer/2010-June/014673.html
I have tried both methods using PET data registered to the surface, but get very different results from fscalc and mri_glmfit. The results I expect are given by fscalc, but I would also like to run the Monte Carlo-based MCC, which requires a glmdir. Is there another way to run MC MCC on the z-map generated by fscal or alternatively, is the code that I am using for glmfit wrong? A simplified version of the code for both analyses is below. I am using FS 5.3 with the fsl binaries from the release notes on mac OS 10.8.
Thanks for your help Jon
----------------------------------mri_glmfit: mris_preproc --target fsaverage --hemi lh --iv nc01_mrispace_pet.mgz nc01_mrispace_pet_2_T1_register.dat --iv nc02_mrispace_pet.mgz nc02_mrispace_pet_2_T1_register.dat --iv nc03_mrispace_pet.mgz nc03_mrispace_pet_2_T1_register.dat --iv pat01_mrispace_pet.mgz pat01_mrispace_pet_2_T1_register.dat --pf 0.5 --out lh.pat01_allcontrols_pet_ztest_pf05_fsaverage.mgh
mri_surf2surf --hemi lh --s fsaverage --fwhm 10 --cortex --sval lh.pat01_allcontrols_pet_ztest_pf05_fsaverage.mgh --tval lh.pat01_allcontrols_pet_ztest_pf05_fsaverage_fwhm10.mgh; done
mri_glmfit --y lh.pat01_allcontrols_pet_ztest_pf05_fsaverage_fwhm10.mgh --fsgd patient1_allcontrols_ztest.fsgd dods --C group2_cov0_diff.mtx --surf fsaverage lh --cortex --glmdir lh.pat01_allcontrols_pet_ztest_pf05_fsaverage_fwhm10.glmdir
*patient1_allcontrols_ztest.fsgd*: GroupDescriptorFile 1 Title patient01_ztest Class Patient Class Control Input pat01 Patient Input nc01 Control Input nc02 Control Input nc03 Control
*group2_cov0_diff.mtx*: -1 1
----------------------------------fscalc.fsl: mris_preproc --target fsaverage --hemi lh --iv nc01_mrispace_pet.mgz nc01_mrispace_pet_2_T1_register.dat --iv nc02_mrispace_pet.mgz nc02_mrispace_pet_2_T1_register.dat --iv nc03_mrispace_pet.mgz nc03_mrispace_pet_2_T1_register.dat --pf 0.5 --out lh.allcontrols_pet_ztest_pf05_fsaverage.mgh
mris_preproc --target fsaverage --hemi lh --iv pat01_mrispace_pet.mgz pat01_mrispace_pet_2_T1_register.dat --pf 0.5 --out lh.patient01_pet_ztest_pf05_fsaverage.mgh
for stat in mean std; do mri_concat lh.allcontrols_pet_ztest_pf05_fsaverage.mgh --o lh.allcontrols_pet_ztest_pf05_fsaverage_${stat}.mgh --${stat}; done; done
fscalc.fsl --surf fsaverage lh lh.patient01_pet_ztest_pf05_fsaverage.mgh -sub lh.allcontrols_pet_ztest_pf05_fsaverage_mean.mgh -div lh.allcontrols_pet_ztest_pf05_fsaverage_std.mgh lh.patient01_vs_allcontrols_pet_ztest_pf05_fsaverage_zmap.mgh; done
Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
-- Douglas N. Greve, Ph.D. MGH-NMR Center greve@nmr.mgh.harvard.edu Phone Number: 617-724-2358 Fax: 617-726-7422
Bugs: surfer.nmr.mgh.harvard.edu/fswiki/BugReporting FileDrop: https://gate.nmr.mgh.harvard.edu/filedrop2 www.nmr.mgh.harvard.edu/facility/filedrop/index.html Outgoing: ftp://surfer.nmr.mgh.harvard.edu/transfer/outgoing/flat/greve/
freesurfer@nmr.mgh.harvard.edu