sorry, I don't understand the question. It looks like the design matrix
is right. It looks like the contrasts tests for a diff between AD and
controls. What else do you need?
On 6/13/16 8:49 AM, Hao wen wrote:
Hello:
I am still confused about how to make the design matrix in FS for
group analysis:
I want to create a design matrix like this: X = 1 + TermAge +
TermGender * TermGroup (this should be like
Age
Female
*
AD
Male
*
AD
Female
*
CN
Male
*
CN
)
There are just 5 columns, not like DODS, we have 8 columns:
Here is my commandline process:
1) in mris_preproc, we gathered the thickness info from every
subjects, the cml is as below:
mris_preproc --fsgd AD_CN_COVARIATES_AGE_GENDER.fsgd \
--cache-in thickness.fwhm15.fsaverage \
--target fsaverage \
--hemi lh \
--out lh.AD_CN_COVARIATES_AGE_GENDER_thickness_15.mgh
after this we use mri_glmfit :
mri_glmfit --glmdir lh.AD_CN_COVARIAETS_AGE_GENDER.glmdir\
--y lh.AD_CN_COVARIATES_AGE_GENDER_thickness_15.mgh \
--C Contrast.mtx \
--X X_5_intersect.mat\
--surf fsaverage lh \
--cortex
After this command:
In the command here, the Contrast.mtx is +0.00000 +1.00000 +1.00000
-1.00000 -1.00000 ,but it the result turns out that the contrast
should be +0.00000 -1.00000 -1.00000 +1.00000 +1.00000, cuz the
thickness of CN should be bigger than that of AD, so my question is
how to know which colomn in the contrastshould be Female*CN, Male*CN,
Female*AD, Male*AD, I know in DODS, DOSS, this is related how do you
how you order your class in the FSGD file, but here, I just have 5
columns, I dont know how to make the correspondences, I can just
deduce it from my results, so I attached my FSGD file for you!
the design matrix is , Xg.dat, I ceate the design matrix,
design_matrix.mat from matlab:
+74.30000 +0.00000 +0.00000 +0.00000 +1.00000
+73.70000 +0.00000 +0.00000 +0.00000 +1.00000
+84.50000 +0.00000 +0.00000 +1.00000 +0.00000
+78.50000 +0.00000 +0.00000 +1.00000 +0.00000
+80.80000 +0.00000 +0.00000 +0.00000 +1.00000
+65.40000 +0.00000 +0.00000 +0.00000 +1.00000
+73.10000 +0.00000 +0.00000 +1.00000 +0.00000
+72.60000 +0.00000 +0.00000 +1.00000 +0.00000
+63.20000 +0.00000 +0.00000 +0.00000 +1.00000
+71.70000 +0.00000 +0.00000 +0.00000 +1.00000
+77.70000 +0.00000 +0.00000 +1.00000 +0.00000
+76.90000 +0.00000 +0.00000 +0.00000 +1.00000
+73.20000 +0.00000 +0.00000 +0.00000 +1.00000
+76.20000 +0.00000 +0.00000 +0.00000 +1.00000
+84.70000 +0.00000 +0.00000 +0.00000 +1.00000
+69.60000 +0.00000 +0.00000 +1.00000 +0.00000
+70.10000 +0.00000 +0.00000 +0.00000 +1.00000
+70.90000 +0.00000 +0.00000 +1.00000 +0.00000
+77.00000 +0.00000 +0.00000 +1.00000 +0.00000
+74.50000 +0.00000 +0.00000 +0.00000 +1.00000
+74.40000 +0.00000 +0.00000 +1.00000 +0.00000
+72.90000 +0.00000 +0.00000 +0.00000 +1.00000
+74.00000 +0.00000 +0.00000 +0.00000 +1.00000
+70.60000 +0.00000 +0.00000 +0.00000 +1.00000
+78.20000 +0.00000 +0.00000 +0.00000 +1.00000
+70.60000 +0.00000 +0.00000 +0.00000 +1.00000
+80.30000 +0.00000 +0.00000 +1.00000 +0.00000
+65.10000 +0.00000 +0.00000 +0.00000 +1.00000
+69.80000 +0.00000 +0.00000 +0.00000 +1.00000
+71.10000 +0.00000 +0.00000 +0.00000 +1.00000
+81.30000 +0.00000 +1.00000 +0.00000 +0.00000
+75.40000 +0.00000 +1.00000 +0.00000 +0.00000
+73.90000 +1.00000 +0.00000 +0.00000 +0.00000
+64.10000 +0.00000 +1.00000 +0.00000 +0.00000
+80.10000 +0.00000 +1.00000 +0.00000 +0.00000
+78.30000 +0.00000 +1.00000 +0.00000 +0.00000
+73.20000 +0.00000 +1.00000 +0.00000 +0.00000
+75.30000 +1.00000 +0.00000 +0.00000 +0.00000
+65.60000 +0.00000 +1.00000 +0.00000 +0.00000
+62.40000 +0.00000 +1.00000 +0.00000 +0.00000
+77.20000 +1.00000 +0.00000 +0.00000 +0.00000
+70.70000 +1.00000 +0.00000 +0.00000 +0.00000
+70.10000 +1.00000 +0.00000 +0.00000 +0.00000
+82.60000 +1.00000 +0.00000 +0.00000 +0.00000
+80.20000 +1.00000 +0.00000 +0.00000 +0.00000
+65.90000 +1.00000 +0.00000 +0.00000 +0.00000
+59.70000 +1.00000 +0.00000 +0.00000 +0.00000
+71.80000 +0.00000 +1.00000 +0.00000 +0.00000
+72.40000 +1.00000 +0.00000 +0.00000 +0.00000
+80.50000 +1.00000 +0.00000 +0.00000 +0.00000
+62.90000 +0.00000 +1.00000 +0.00000 +0.00000
+67.40000 +0.00000 +1.00000 +0.00000 +0.00000
+80.20000 +1.00000 +0.00000 +0.00000 +0.00000
+85.50000 +0.00000 +1.00000 +0.00000 +0.00000
+65.90000 +0.00000 +1.00000 +0.00000 +0.00000
+89.10000 +1.00000 +0.00000 +0.00000 +0.00000
+56.40000 +0.00000 +1.00000 +0.00000 +0.00000
+82.70000 +0.00000 +1.00000 +0.00000 +0.00000
+68.30000 +0.00000 +1.00000 +0.00000 +0.00000
+74.00000 +0.00000 +1.00000 +0.00000 +0.00000
So my question is how to correspond the different column to the
contrast matrix and this (
Age
Female
*
AD
Male
*
AD
Female
*
CN
Male
*
CN
)
So , do you have some specific tutorial for this kind of analysis, if
not, can you clarify this to me a little and I would like to make a
tutorial for this, cuz
------------------------------------------------------------------------
*De :* freesurfer-boun...@nmr.mgh.harvard.edu
<freesurfer-boun...@nmr.mgh.harvard.edu> de la part de Hao wen
<hao.freesur...@hotmail.com>
*Envoyé :* vendredi 10 juin 2016 11:10:37
*À :* freesurfer@nmr.mgh.harvard.edu
*Objet :* [Freesurfer] GLM: Define the design matrix by myself
Hello, Freesurfer experts:
I want to define the design matrix by myself in GLM, I know that in
FS, when we deal with the categorized factors, we treat them as
classes, So basically, I want to make a design matrix like this:
1) formula_EffectOnGroupWithAgeGenderCovariates = 1 + TermGroup +
TermAge + TermGender
and
2) formula_EffectOnGroupWithAgeGenderInterectionCovariates = 1 +
TermAge + TermGender * TermGroup
Here, TermGroup and TermGender are categorized factors, so I know that
we can make the design matrix like 2) in FS, cuz here we define it as
intersection, but my question is that if wen can define a matrix like
the first one? I know in SurfStat, we can define it like 1)
Hope to hear from you soon:)
thank you in advance!
_______________________________________________
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
_______________________________________________
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.