Hello,
I have been attempting to run a between group DTI contrast using
glmfit, and it could not determine how to produce the data that is
given to mri_glmfit as its input. My approach below may be wrong, so
if you can recommend a better way of doing it please advise. Assuming
this method is a valid approach, here is my technical problem: the
resampling step shown below seems to work, but glmfit reports that
there is an incorrect number of rows, so I guess something goes
wrong.
The first thing I do is resample from volume to surface onto average7
for each of the subjects:
cat Subject_Lists/bw-group-error-dti-5 | while
read sub ; do
mri_vol2surf \
--src "$sub"/dti/unwarp/maps/sreg/fa.bhdr \
--srcreg "$sub"/bold/register.dat \
--trgsubject average7 \
--out DTI_HCvASD_mriglfmit/surface/"$sub"_fa.mgh \
--hemi lh
done
And then I create a final output to give to mri_glmfit:
mri_concat
DTI_HCvASD_mriglfmit/surface/mano*_fa.mgh --o
DTI_HCvASD_mriglfmit/all_fa.mgh
The process I'm attempting above is similar to what mris_preproc uses
surf2surf to do, but I think I need to use vol2surf instead of
surf2surf. As far as I can tell mris_preproc would not
work, because in what I am doing I need to go from the volume to the
surface. This vol2surf method "works" in
that it doesn't have any errors when running (though some warnings
about registration file being different from source file), and it
generates the
resampled surface that I concatenate at the end. So far so good
but when I run mri_glmfit, I get an error message (see below).
mri_glmfit \
--really-use-average7 \
--y DTI_HCvASD_mriglfmit/all_fa.mgh \
--fsgd fsgd_and_contrast_files/BwGroupErrorDTI5.fsgd \
--glmdir DTI_HCvASD_mriglfmit/HCvASD.fsfast.glmdir \
--C fsgd_and_contrast_files/BwGroupErrorDTI5.mat
sysname Linux
hostname vantz
machine x86_64
user levy
FixVertexAreaFlag = 1
UseMaskWithSmoothing 1
OneSampleGroupMean 0
y /autofs/space/ventzl_015/users/DTI_HCvASD_mriglfmit/all_fa.mgh
logyflag 0
usedti 0
FSGD fsgd_and_contrast_files/BwGroupErrorDTI5.fsgd
glmdir DTI_HCvASD_mriglfmit/HCvASD.fsfast.glmdir
DoFFx 0
Creating output directory DTI_HCvASD_mriglfmit/HCvASD.fsfast.glmdir
Loading y from
/autofs/space/ventzl_015/users/DTI_HCvASD_mriglfmit/all_fa.mgh
Matrix condition is 1
Pruning voxels by frame.
Found 155495 voxels in mask
Saving mask to DTI_HCvASD_mriglfmit/HCvASD.fsfast.glmdir/mask.mgh
search space = 155495
ERROR: dimension mismatch between y and X.
y has 23 inputs, X has 24 rows.
My .fsgd file matches the exact set of subjects that went into the
aggregate .mgh file, so that isn't the reason.
What do you think might be the cause of this error?
Thanks,
Rob
Also, here is some information on the environment I ran these commands
in:
--------
freesurfer-Linux-centos4_x86_64-dev-20070819 --------
Setting up environment for FreeSurfer/FS-FAST (and FSL)
FREESURFER_HOME /usr/local/freesurfer/dev
FSFAST_HOME /usr/local/freesurfer/dev/fsfast
FSF_OUTPUT_FORMAT nii
SUBJECTS_DIR /space/ventzl/1/users/SUBJECTS_DIR
MNI_DIR /usr/local/freesurfer/dev/mni
FSL_DIR /usr/local/freesurfer/dev/fsl
[vantz:SUBJECTS_DIR] (nmr-dev-env) pwd
/space/ventzl/1/users/SUBJECTS_DIR
--
Robert P. Levy, B.A.
Research Assistant, Manoach Lab
Massachusetts General Hospital
Charlestown Navy Yard
149 13th St., Room 2611
Charlestown, MA 02129
email: levy@nmr.mgh.harvard.edu
phone: 617-726-1908
fax: 617-726-4078
http://nmr.mgh.harvard.edu/manoachlab