[Freesurfer] Fw: longitudinal statistics LGI
From: Jon Alan Wieser Sent: Tuesday, December 30, 2014 8:11 PM To: jorge luis Cc: Kristin Elizabeth Maple Subject: Re: [Freesurfer] longitudinal statistics LGI Hi Jorge, Following your instructions, so far we have done the following: 1-Read your label lhcortex = fs_read_label('freesurfer/subjects/fsaverage/label/lh.cortex.label'); 2-Read the data file [lhY, lhmri] = fs_read_Y('lh.thickness.mgh'); 3-Fit a vertex-wise lme model with two random effects for the intercept term and time eg.: lhstats1 = lme_mass_fit_vw(X, [1 2], lhY, ni, lhcortex); 4-Fit a vertex-wise lme model with two random effects for the intercept term and cannabis use eg.: lhstats2 = lme_mass_fit_vw(X, [1 3], lhY, ni, lhcortex); lhstats3 = lme_mass_fit_vw(X, [1 2 6], lhY, ni, lhcortex); %intercept_time_gender lhstats4 = lme_mass_fit_vw(X, [1 2 7], lhY, ni, lhcortex); %intercept_time_age lhstats5 = lme_mass_fit_vw(X, [1 2 3 6 ], lhY, ni, lhcortex); %intercept_time_cannabis_gender We displayed the lREML data on the surface models in matlab. In some cases,(when there were 3 or more effects ( i.e. 1 2 6) ) the lreml values had real and imaginary values, so I displayed the ABS value of the lreml We need to know the following: 1. How do we model this: Intercept, time, age, gender, Alcohol, other drugs vs. Intercept, time, age, Gender, Alcohol, Other drug, cannabis 2. Correct for multiple comparisons 3. Open these in Freesurfer, significance maps using tksurfer ( P < 0.05) Is it only visual, or is there a significance test between the two models 4. How do we get a map that demonstrates the unique effect of cannabis 5. What Contrast matrix do we use for the LME_mass_F program Thanks Jon From: jorge luis Sent: Wednesday, December 17, 2014 9:25 AM To: Freesurfer support list; Jon Alan Wieser Cc: Krista Lisdahl Medina; alicia.thomas@gmail.com Subject: Re: [Freesurfer] longitudinal statistics LGI Hi Jon We recommend to order the columns of your design matrix in the following way: First, the intercept term (which is a column of ones); second, the time covariate; third, any time-varying covariates (eg. cannabis use); fourth, the group covariates of interest (eg. a binary variable indicating whether the subject is a patient or control) and their interactions with the time-varying covariates; finally any other nuisance time-invariant covariate (eg. gender). So your design matrix is comprised by the following columns: 1. Intercept (a column of ones) 2. Time since baseline 3. cannabis use (time-varying if varies over time for each subject during the follow-up time) 4. alcohol use (time-varying if varies over time for each subject during the follow-up time) 5. drug use over time (time-varying if varies over time for each subject during the follow-up time) 6. gender 7. age at baseline There is no GUI for setting up the models. Here is an outline of the basic steps (with only three time points you shouldn't need more than two random effects): 1-Read your label eg.: lhcortex = fs_read_label('freesurfer/subjects/fsaverage/label/lh.cortex.label'); 2-Read the data file eg.: [lhY, lhmri] = fs_read_Y('lh.thickness.mgh'); 3-Fit a vertex-wise lme model with two random effects for the intercept term and time eg.: lhstats1 = lme_mass_fit_vw(X, [1 2], lhY, ni, lhcortex); 4-Fit a vertex-wise lme model with two random effects for the intercept term and cannabis use eg.: lhstats2 = lme_mass_fit_vw(X, [1 3], lhY, ni, lhcortex); And so on with other time-variying covariates... Now see which model fit produces the best lreml values across vertices in general and then: 4-Perform vertex-wise inferences using the winner model eg.: CM.C = [your contrast matrix]; F_lhstats = lme_mass_F(lhstats_winner, CM); 5-Save results eg.: fs_write_fstats(F_lhstats, lhmri,' sig.mgh', 'sig'); -Jorge De: Jon Alan Wieser Para: jorge luis ; Freesurfer support list CC: Krista Lisdahl Medina ; "alicia.thomas@gmail.com" Enviado: Martes 16 de diciembre de 2014 15:24 Asunto: Re: [Freesurfer] longitudinal statistics LGI Jorge, We are interested in examining the impact of cannabis exposure (time-varying continuous variable) on local gyrification index over 3 time points (baseline, 18 month, 36 month)- so this is a time-varying random effect. I apologize in advance if these are student questions… we are novices here… From what you said previously, we would want to model intercept+time, vs intercept+cannabis use, vs intercept+time+ cannabis use. Vs. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time). We are trying to figure out how to do this in Freesurfer/Matlab using the Wiki (https://surfer.nmr.mgh.harvard.edu/fswiki/LinearMixedEffectsModels)
[Freesurfer] Fw: longitudinal statistics LGI
From: Jon Alan Wieser Sent: Monday, January 5, 2015 11:13 AM To: jorge luis; Freesurfer support list Subject: Re: [Freesurfer] longitudinal statistics LGI HI Jorge, how do you determine the number of rows(L) in the contrast matrix? so if we want to test the effect of cannabis usage, which is the third column in our design matrix : would our contrast matrix be something like: CM.C = [0 0 1 0 0 0 0] or CM.C = [0 0 1 0 0 0 0; 0 0 -1 0 0 0 0; 0 0 0 0 0 0 0] our design matrix: 1. Intercept (a column of ones) 2. Time since baseline 3. cannabis use (time-varying if varies over time for each subject during the follow-up time) 4. alcohol use (time-varying if varies over time for each subject during the follow-up time) 5. drug use over time (time-varying if varies over time for each subject during the follow-up time) 6. gender 7. age at baseline Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of jorge luis Sent: Saturday, January 3, 2015 1:50 PM To: Freesurfer support list Subject: Re: [Freesurfer] longitudinal statistics LGI Hi Jon Your contrast matrix depends on the hypothesis you want to test. Contrast matrices for lme are specified in the same way as for the General Linear Model. Nothing different here. It's a matrix of L rows where L>=1 and the same number of columns as the number of fixed effects (population parameters) in your model. Best -Jorge ____ De: Jon Alan Wieser Para: jorge luis CC: "freesurfer (freesurfer@nmr.mgh.harvard.edu)" Enviado: Domingo 28 de diciembre de 2014 10:23 Asunto: Re: [Freesurfer] longitudinal statistics LGI HI Jorge What should we use for our Contrast Matrix (CM) ? Jon From: jorge luis Sent: Wednesday, December 17, 2014 9:25 AM To: Freesurfer support list; Jon Alan Wieser Cc: Krista Lisdahl Medina; alicia.thomas@gmail.com Subject: Re: [Freesurfer] longitudinal statistics LGI Hi Jon We recommend to order the columns of your design matrix in the following way: First, the intercept term (which is a column of ones); second, the time covariate; third, any time-varying covariates (eg. cannabis use); fourth, the group covariates of interest (eg. a binary variable indicating whether the subject is a patient or control) and their interactions with the time-varying covariates; finally any other nuisance time-invariant covariate (eg. gender). So your design matrix is comprised by the following columns: 1. Intercept (a column of ones) 2. Time since baseline 3. cannabis use (time-varying if varies over time for each subject during the follow-up time) 4. alcohol use (time-varying if varies over time for each subject during the follow-up time) 5. drug use over time (time-varying if varies over time for each subject during the follow-up time) 6. gender 7. age at baseline There is no GUI for setting up the models. Here is an outline of the basic steps (with only three time points you shouldn't need more than two random effects): 1-Read your label eg.: lhcortex = fs_read_label('freesurfer/subjects/fsaverage/label/lh.cortex.label'); 2-Read the data file eg.: [lhY, lhmri] = fs_read_Y('lh.thickness.mgh'); 3-Fit a vertex-wise lme model with two random effects for the intercept term and time eg.: lhstats1 = lme_mass_fit_vw(X, [1 2], lhY, ni, lhcortex); 4-Fit a vertex-wise lme model with two random effects for the intercept term and cannabis use eg.: lhstats2 = lme_mass_fit_vw(X, [1 3], lhY, ni, lhcortex); And so on with other time-variying covariates... Now see which model fit produces the best lreml values across vertices in general and then: 4-Perform vertex-wise inferences using the winner model eg.: CM.C = [your contrast matrix]; F_lhstats = lme_mass_F(lhstats_winner, CM); 5-Save results eg.: fs_write_fstats(F_lhstats, lhmri,' sig.mgh', 'sig'); -Jorge De: Jon Alan Wieser Para: jorge luis ; Freesurfer support list CC: Krista Lisdahl Medina ; "alicia.thomas@gmail.com" Enviado: Martes 16 de diciembre de 2014 15:24 Asunto: Re: [Freesurfer] longitudinal statistics LGI Jorge, We are interested in examining the impact of cannabis exposure (time-varying continuous variable) on local gyrification index over 3 time points (baseline, 18 month, 36 month)- so this is a time-varying random effect. I apologize in advance if these are student questions… we are novices here… From what you said previously, we would want to model intercept+time, vs intercept+cannabis use, vs intercept+time+ cannabis use. Vs. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time). We are trying to figure out how to do this in Freesurfer/Matlab using the Wiki (https://surfer.nmr.mgh.harvard.edu/fswiki/LinearMixedEffectsModels). There is a great example in
[Freesurfer] tkmedit neuroscience format
Dear freesurfer experts. is it possible for tkmedit to display volumes in neuroscience format (R is R) rather than radiologic format (R is L)?" Thanks Jon ___ 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.
[Freesurfer] TKMEDIT error when SSH'ing
Hi Freesurfer folks I am SSH'ing from one MAC to another. both mac's are running Mac Os 10.6.8 I am ssh'ing with -Y option when I try to run tkmedit I get the error; Thu May 21 09:54:24 cerebrum.uwm.edu tkmedit.bin[56625] : kCGErrorIllegalArgument: _CGSFindSharedWindow: WID 2763 Thu May 21 09:54:24 cerebrum.uwm.edu tkmedit.bin[56625] : kCGErrorFailure: Set a breakpoint @ CGErrorBreakpoint() to catch errors as they are logged. Thu May 21 09:54:24 cerebrum.uwm.edu tkmedit.bin[56625] : kCGErrorIllegalArgument: CGSSetWindowSendExposed: Invalid window 0xacb Thu May 21 09:54:24 cerebrum.uwm.edu tkmedit.bin[56625] : unknown error code: invalid drawable error: xp_attach_gl_context returned: 2 X Error of failed request: 0 Major opcode of failed request: 150 (GLX) Minor opcode of failed request: 26 (X_GLXMakeContextCurrent) Serial number of failed request: 24 Current serial number in output stream: 24 How can I fix this? Jon ___ 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.
Re: [Freesurfer] TKMEDIT error when SSH'ing
tkmedit works fine on the machine, when working directly on it (not ssh'ing to it) Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of zkauf...@nmr.mgh.harvard.edu Sent: Thursday, May 21, 2015 11:53 AM To: Freesurfer support list Cc: freesurfer Subject: Re: [Freesurfer] TKMEDIT error when SSH'ing Have you verified that the machine you are ssh'ing into will display tkmedit even if you are not ssh'ing into it? I ask because OSX 10.6 is an end-of-life operating system and that error is usually associated with incompatible graphics card. However, even if it did work while sitting at the host machine, I have never been able to successfully perform X Forwarding over ssh from one Mac to another Mac when using the tktools, or any graphical tools that I can recall for that matter. -Zeke > Hi Freesurfer folks > > I am SSH'ing from one MAC to another. both mac's are running Mac Os > 10.6.8 > > I am ssh'ing with -Y option > > when I try to run tkmedit I get the error; > > > Thu May 21 09:54:24 cerebrum.uwm.edu tkmedit.bin[56625] : > kCGErrorIllegalArgument: _CGSFindSharedWindow: WID 2763 > Thu May 21 09:54:24 cerebrum.uwm.edu tkmedit.bin[56625] : > kCGErrorFailure: Set a breakpoint @ CGErrorBreakpoint() to catch errors as > they are logged. > Thu May 21 09:54:24 cerebrum.uwm.edu tkmedit.bin[56625] : > kCGErrorIllegalArgument: CGSSetWindowSendExposed: Invalid window 0xacb > Thu May 21 09:54:24 cerebrum.uwm.edu tkmedit.bin[56625] : unknown > error code: invalid drawable > error: xp_attach_gl_context returned: 2 > X Error of failed request: 0 > Major opcode of failed request: 150 (GLX) > Minor opcode of failed request: 26 (X_GLXMakeContextCurrent) > Serial number of failed request: 24 > Current serial number in output stream: 24 > > How can I fix this? > > Jon > > > > > ___ > 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. ___ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
[Freesurfer] qdec error
HI freesurfer experts, I am running a qdec analysis, my first factor has 3 levels, my other 2 factors have 2 levels, I select my first and second factors and hit "Analyze" I get the error ? : Error in Analyze: command failed ERROR: QdecGlmDesign::GenerateContrasts: factor 1 must have 2 levels how can I analyze with a factor that has three levels? thanks JOn ___ 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.
[Freesurfer] qdec error
I'm getting the following erorr when running Qdec "Analyze" Model Factors: Discrete (fixed factors) ADHD_Persist MJ_group Nuisance factor: Age ERROR: matrix is ill-conditioned or badly scaled, condno = 10355.4 Possible problem with experimental design: Check for duplicate entries and/or lack of range of continuous variables within a class. If you seek help with this problem, make sure to send: 1. Your command line: mri_glmfit --y /Studies/MTA/qdec/MTA_persistanceCD/y.mgh --fsgd /Studies/MTA/qdec/MTA_persistanceCD/qdec.fsgd dods --glmdir /Studies/MTA/qdec/MTA_persistanceCD --surf fsaverage rh --label /Studies/MTA/fsaverage/label/rh.aparc.label --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Avg-Intercept-thickness.mat --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-C-D-Intercept-thickness.mat --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-Control-MJuser-Intercept-thickness.mat --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-X-ADHD_Persist-MJ_group-Intercept-thickness.mat 2. The FSGD file (if using one) 3. And the design matrix above Error in Analyze: command failed: mri_glmfit --y /Studies/MTA/qdec/MTA_persistanceCD/y.mgh --fsgd /Studies/MTA/qdec/MTA_persistanceCD/qdec.fsgd dods --glmdir /Studies/MTA/qdec/MTA_persistanceCD --surf fsaverage rh --label /Studies/MTA/fsaverage/label/rh.aparc.label --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Avg-Intercept-thickness.mat --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-C-D-Intercept-thickness.mat --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-Control-MJuser-Intercept-thickness.mat --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-X-ADHD_Persist-MJ_group-Intercept-thickness.mat command line: mri_glmfit --y /Studies/MTA/qdec/MTA_persistanceCD/y.mgh --fsgd /Studies/MTA/qdec/MTA_persistanceCD/qdec.fsgd dods --glmdir /Studies/MTA/qdec/MTA_persistanceCD --surf fsaverage rh --label /Studies/MTA/fsaverage/label/rh.aparc.label --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Avg-Intercept-thickness.mat --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-C-D-Intercept-thickness.mat --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-Control-MJuser-Intercept-thickness.mat --C /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-X-ADHD_Persist-MJ_group-Intercept-thickness.mat no FSGD file I have attached the qdec dat file design matrix: Design matrix -- 1.000 0.000 0.000 0.000 25.000 0.000 0.000 0.000; 1.000 0.000 0.000 0.000 24.000 0.000 0.000 0.000; 1.000 0.000 0.000 0.000 22.000 0.000 0.000 0.000; 1.000 0.000 0.000 0.000 23.000 0.000 0.000 0.000; 1.000 0.000 0.000 0.000 24.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 25.000 0.000; 1.000 0.000 0.000 0.000 23.000 0.000 0.000 0.000; 1.000 0.000 0.000 0.000 21.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 21.000 0.000; 0.000 1.000 0.000 0.000 0.000 25.000 0.000 0.000; 0.000 1.000 0.000 0.000 0.000 23.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 26.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 23.000 0.000; 1.000 0.000 0.000 0.000 24.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 25.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 22.000 0.000; 1.000 0.000 0.000 0.000 23.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 21.000 0.000; 1.000 0.000 0.000 0.000 25.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 24.000 0.000; 1.000 0.000 0.000 0.000 23.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 23.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 23.000 0.000; 1.000 0.000 0.000 0.000 23.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 26.000 0.000; 1.000 0.000 0.000 0.000 24.000 0.000 0.000 0.000; 1.000 0.000 0.000 0.000 25.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 23.000 0.000; 1.000 0.000 0.000 0.000 27.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 24.000 0.000; 1.000 0.000 0.000 0.000 23.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 24.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 23.000 0.000; 1.000 0.000 0.000 0.000 23.000 0.000 0.000 0.000; 1.000 0.000 0.000 0.000 21.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 25.000 0.000; 1.000 0.000 0.000 0.000 24.000 0.000 0.000 0.000; 0.000 0.000 1.000 0.000 0.000 0.000 24.000 0.000; 0.000
[Freesurfer] MRI_glmfit-sim error
I'm running a monte carlo sim and am getting an error: command line: mri_glmfit-sim \ --glmdir MTA_persistanceCP \ --sim mc-z 1000 1.3 mc-z.negative \ --sim-sign abs --cwpvalthresh 0.999 \ --overwrite output: cmdline mri_glmfit --y /Studies/MTA/qdec/MTA_persistanceCP/y.mgh --fsgd /Studies/MTA/qdec/MTA_persistanceCP/qdec.fsgd dods --glmdir /Studies/MTA/qdec/MTA_persistanceCP --surf fsaverage rh --label /Studies/MTA/fsaverage/label/rh.aparc.label --C /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Avg-Intercept-thickness.mat --C /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Diff-F-M-Intercept-thickness.mat SURFACE: fsaverage rh log file is MTA_persistanceCP/mc-z.negative.mri_glmfit-sim.log cd /Studies/MTA/qdec /Applications/freesurfer/bin/mri_glmfit-sim --glmdir MTA_persistanceCP --sim mc-z 1000 1.3 mc-z.negative --sim-sign abs --cwpvalthresh 0.999 --overwrite $Id: mri_glmfit-sim,v 1.36.2.5 2012/10/01 22:31:37 greve Exp $ Tue Jul 29 14:08:52 CDT 2014 Darwin psy-blackbird.ad.uwm.edu 10.8.0 Darwin Kernel Version 10.8.0: Tue Jun 7 16:32:41 PDT 2011; root:xnu-1504.15.3~1/RELEASE_X86_64 x86_64 wieser setenv SUBJECTS_DIR /Applications/freesurfer/subjects FREESURFER_HOME /Applications/freesurfer Original mri_glmfit command line: cmdline mri_glmfit --y /Studies/MTA/qdec/MTA_persistanceCP/y.mgh --fsgd /Studies/MTA/qdec/MTA_persistanceCP/qdec.fsgd dods --glmdir /Studies/MTA/qdec/MTA_persistanceCP --surf fsaverage rh --label /Studies/MTA/fsaverage/label/rh.aparc.label --C /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Avg-Intercept-thickness.mat --C /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Diff-F-M-Intercept-thickness.mat DoSim = 1 UseCache = 0 DoPoll = 0 DoPBSubmit = 0 DoBackground = 0 DiagCluster = 0 gd2mtx = dods fwhm = 14.370530 nSimPerJob = 1000 1/1 Tue Jul 29 14:08:52 CDT 2014 mri_glmfit --y MTA_persistanceCP/y.mgh --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Avg-Intercept-thickness.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Avg-thickness-Gender-Cor.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-C-P-Cor-thickness-Gender.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-C-P-Intercept-thickness.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-Control-MJuser-Cor-thickness-Gender.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-Control-MJuser-Intercept-thickness.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-F-M-Intercept-thickness.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-X-ADHD_Persist-MJ_group-Cor-thickness-Gender.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-X-ADHD_Persist-MJ_group-Intercept-thickness.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Avg-Intercept-thickness.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Avg-thickness-Gender-Cor.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-C-P-Cor-thickness-Gender.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-C-P-Intercept-thickness.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-Control-MJuser-Cor-thickness-Gender.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-Control-MJuser-Intercept-thickness.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-F-M-Intercept-thickness.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-X-ADHD_Persist-MJ_group-Cor-thickness-Gender.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-X-ADHD_Persist-MJ_group-Intercept-thickness.mtx --mask MTA_persistanceCP/mask.mgh --sim mc-z 1000 1.3 MTA_persistanceCP/csd/mc-z.negative.j001 --sim-sign abs --fwhm 14.370530 --fsgd MTA_persistanceCP/y.fsgd dods --label /Studies/MTA/fsaverage/label/rh.aparc.label --surf fsaverage rh white INFO: ignoring tag Creator INFO: ignoring tag SUBJECTS_DIR INFO: ignoring tag SynthSeed simbase MTA_persistanceCP/csd/mc-z.negative.j001 FWHM = 14.370530 gdfReadHeader: reading MTA_persistanceCP/y.fsgd INFO: NOT demeaning continuous variables Continuous Variable Means (all subjects) 0 Age 23.9348 1.40499 Class Means of each Continuous Variable 1 Gender_MFF 23.8000 2 Gender_MFM 23.9722 INFO: gd2mtx_method is dods Reading source surface /Applications/freesurfer/subjects/fsaverage/surf/rh.white Number of vertices 163842 Number of faces327680 Total area 65020.765625 AvgVtxArea 0.396850 AvgVtxDist 0.717994 StdVtxDist 0.193566 Surface smoothing by fwhm=14.370530, niters=152.00 $Id: mri_glmfit.c,v 1.196.2.8 2012/11/01 18:51:41 greve Exp $ cwd /Studies/MTA/Qdec cmdline mri_glmfit --y MTA_persistanceCP/y.mgh --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Avg-Intercept-thickness.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Avg-thickness-Gender-Cor.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-C-P-Cor-thickness-Gender.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-C-P-Intercept-thickness.mtx --C MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-Control-MJu
Re: [Freesurfer] MRI_glmfit-sim error
I ran the analysis in qdec, not mri_glmfit . I did a few analyses in qdec Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of Douglas N Greve Sent: Tuesday, July 29, 2014 3:48 PM To: freesurfer@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] MRI_glmfit-sim error I'm not sure how that could have happened. Did you run mri_glmfit multiple times by any chance? On 07/29/2014 03:10 PM, Jon Alan Wieser wrote: > > > I'm running a monte carlo sim and am getting an error: > > > command line: > > > mri_glmfit-sim \ > --glmdir MTA_persistanceCP \ > --sim mc-z 1000 1.3 mc-z.negative \ > --sim-sign abs --cwpvalthresh 0.999 \ > --overwrite > > > > output: > > cmdline mri_glmfit --y /Studies/MTA/qdec/MTA_persistanceCP/y.mgh > --fsgd /Studies/MTA/qdec/MTA_persistanceCP/qdec.fsgd dods --glmdir > /Studies/MTA/qdec/MTA_persistanceCP --surf fsaverage rh --label > /Studies/MTA/fsaverage/label/rh.aparc.label --C > /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Avg-Intercept-thickness.mat > --C > /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Diff-F-M-Intercept-thickness.mat > SURFACE: fsaverage rh > log file is MTA_persistanceCP/mc-z.negative.mri_glmfit-sim.log > > cd /Studies/MTA/qdec > /Applications/freesurfer/bin/mri_glmfit-sim > --glmdir MTA_persistanceCP --sim mc-z 1000 1.3 mc-z.negative > --sim-sign abs --cwpvalthresh 0.999 --overwrite > > $Id: mri_glmfit-sim,v 1.36.2.5 2012/10/01 22:31:37 greve Exp $ > Tue Jul 29 14:08:52 CDT 2014 > Darwin psy-blackbird.ad.uwm.edu 10.8.0 Darwin Kernel Version 10.8.0: > Tue Jun 7 16:32:41 PDT 2011; root:xnu-1504.15.3~1/RELEASE_X86_64 x86_64 > wieser > setenv SUBJECTS_DIR /Applications/freesurfer/subjects > FREESURFER_HOME /Applications/freesurfer > > Original mri_glmfit command line: > cmdline mri_glmfit --y /Studies/MTA/qdec/MTA_persistanceCP/y.mgh > --fsgd /Studies/MTA/qdec/MTA_persistanceCP/qdec.fsgd dods --glmdir > /Studies/MTA/qdec/MTA_persistanceCP --surf fsaverage rh --label > /Studies/MTA/fsaverage/label/rh.aparc.label --C > /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Avg-Intercept-thickness.mat > --C > /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Diff-F-M-Intercept-thickness.mat > > DoSim = 1 > UseCache = 0 > DoPoll = 0 > DoPBSubmit = 0 > DoBackground = 0 > DiagCluster = 0 > gd2mtx = dods > fwhm = 14.370530 > nSimPerJob = 1000 > 1/1 Tue Jul 29 14:08:52 CDT 2014 > mri_glmfit --y MTA_persistanceCP/y.mgh --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Avg-Intercept-thickness.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Avg-thickness-Gender-Cor.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-C-P-Cor-thickness-Gender.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-C-P-Intercept-thickness.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-Control-MJuser-Cor-thickness-Gender.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-Control-MJuser-Intercept-thickness.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-F-M-Intercept-thickness.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-X-ADHD_Persist-MJ_group-Cor-thickness-Gender.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-X-ADHD_Persist-MJ_group-Intercept-thickness.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Avg-Intercept-thickness.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Avg-thickness-Gender-Cor.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-C-P-Cor-thickness-Gender.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-C-P-Intercept-thickness.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-Control-MJuser-Cor-thickness-Gender.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-Control-MJuser-Intercept-thickness.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-F-M-Intercept-thickness.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-X-ADHD_Persist-MJ_group-Cor-thickness-Gender.mtx > --C > MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-X-ADHD_Persist-MJ_group-Intercept-thickness.mtx > --mask MTA_persistanceCP/mask.mgh --sim mc-z 1000 1.3 > MTA_persistanceCP/csd/mc-z.negative.j001 --sim-sign abs --fwhm > 14.370530 --fsgd MTA_persistanceCP/y.fsgd dods --label > /Studies/MTA/fsaverage/label/rh.aparc.label --surf fsaverage rh white > INFO: ignoring tag Creator > INFO: ignoring tag SUBJECTS_DIR > INFO: ignoring tag SynthSeed > simbase MTA_persistanceCP/csd/mc-z.negative.j001 > FWHM = 14.370530 > gdfReadHeader: reading MTA_persistanceCP/y.fsgd > INFO: NOT demeaning continuous variables > Continuous Variable Means (all subject
Re: [Freesurfer] qdec error
that fixed the problem Thanks Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of Douglas N Greve Sent: Tuesday, July 29, 2014 4:27 PM To: freesurfer@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] qdec error Try removing the mean from the age. By this I mean to compute the mean age over all subjects regardless of group, then subtract the mean from all ages. doug On 07/29/2014 02:39 PM, Jon Alan Wieser wrote: > > I'm getting the following erorr when running Qdec "Analyze" > > Model Factors: > > > Discrete (fixed factors) > > ADHD_Persist > > MJ_group > > Nuisance factor: > > Age > > > ERROR: matrix is ill-conditioned or badly scaled, condno = 10355.4 > > Possible problem with experimental design: > Check for duplicate entries and/or lack of range of > continuous variables within a class. > > If you seek help with this problem, make sure to send: > 1. Your command line: > mri_glmfit --y /Studies/MTA/qdec/MTA_persistanceCD/y.mgh --fsgd > /Studies/MTA/qdec/MTA_persistanceCD/qdec.fsgd dods --glmdir > /Studies/MTA/qdec/MTA_persistanceCD --surf fsaverage rh --label > /Studies/MTA/fsaverage/label/rh.aparc.label --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Avg-Intercept-thickness.mat > --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-C-D-Intercept-thickness.mat > --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-Control-MJuser-Intercept-thickness.mat > --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-X-ADHD_Persist-MJ_group-Intercept-thickness.mat > 2. The FSGD file (if using one) > 3. And the design matrix above > Error in Analyze: command failed: mri_glmfit --y > /Studies/MTA/qdec/MTA_persistanceCD/y.mgh --fsgd > /Studies/MTA/qdec/MTA_persistanceCD/qdec.fsgd dods --glmdir > /Studies/MTA/qdec/MTA_persistanceCD --surf fsaverage rh --label > /Studies/MTA/fsaverage/label/rh.aparc.label --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Avg-Intercept-thickness.mat > --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-C-D-Intercept-thickness.mat > --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-Control-MJuser-Intercept-thickness.mat > --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-X-ADHD_Persist-MJ_group-Intercept-thickness.mat > > > > > > command line: > > mri_glmfit --y /Studies/MTA/qdec/MTA_persistanceCD/y.mgh --fsgd > /Studies/MTA/qdec/MTA_persistanceCD/qdec.fsgd dods --glmdir > /Studies/MTA/qdec/MTA_persistanceCD --surf fsaverage rh --label > /Studies/MTA/fsaverage/label/rh.aparc.label --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Avg-Intercept-thickness.mat > --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-C-D-Intercept-thickness.mat > --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-Diff-Control-MJuser-Intercept-thickness.mat > --C > /Studies/MTA/qdec/MTA_persistanceCD/contrasts/rh-X-ADHD_Persist-MJ_group-Intercept-thickness.mat > > > > no FSGD file > > > I have attached the qdec dat file > > > > > design matrix: > > Design matrix -- > 1.000 0.000 0.000 0.000 25.000 0.000 0.000 0.000; > 1.000 0.000 0.000 0.000 24.000 0.000 0.000 0.000; > 1.000 0.000 0.000 0.000 22.000 0.000 0.000 0.000; > 1.000 0.000 0.000 0.000 23.000 0.000 0.000 0.000; > 1.000 0.000 0.000 0.000 24.000 0.000 0.000 0.000; > 0.000 0.000 1.000 0.000 0.000 0.000 25.000 0.000; > 1.000 0.000 0.000 0.000 23.000 0.000 0.000 0.000; > 1.000 0.000 0.000 0.000 21.000 0.000 0.000 0.000; > 0.000 0.000 1.000 0.000 0.000 0.000 21.000 0.000; > 0.000 1.000 0.000 0.000 0.000 25.000 0.000 0.000; > 0.000 1.000 0.000 0.000 0.000 23.000 0.000 0.000; > 0.000 0.000 1.000 0.000 0.000 0.000 26.000 0.000; > 0.000 0.000 1.000 0.000 0.000 0.000 23.000 0.000; > 1.000 0.000 0.000 0.000 24.000 0.000 0.000 0.000; > 0.000 0.000 1.000 0.000 0.000 0.000 25.000 0.000; > 0.000 0.000 1.000 0.000 0.000 0.000 22.000 0.000; > 1.000 0.000 0.000 0.000 23.000 0.000 0.000 0.000; > 0.000 0.000 1.000 0.000 0.000 0.000 21.000 0.000; > 1.000 0.000 0.000 0.000 25.000 0.000 0.000 0.000; > 0.000 0.000 1.000 0.000 0.000 0.000 24.000 0.000; > 1.000 0.000 0.000 0.000 23.000 0.000 0.000 0.000; > 0.000 0.000 1.000 0.000 0.000 0.000 23.000 0.000; > 0.000 0.000 1.000 0.000 0.000 0.000 23.000 0.000; > 1.000 0.000
Re: [Freesurfer] MRI_glmfit-sim error
I deleted the output folder, then reran each contrast into a separate output folder. problem solved! Thanks! Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of Douglas N Greve Sent: Tuesday, July 29, 2014 3:59 PM To: freesurfer@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] MRI_glmfit-sim error I think that could be the problem. I don't think that qdec cleans up after itself, so that is probably a contrast from another analysis. Try rerunning qdec using a different output folder, or just delete that contrast. doug On 07/29/2014 04:52 PM, Jon Alan Wieser wrote: > I ran the analysis in qdec, not mri_glmfit . I did a few analyses in qdec > > Jon > > From: freesurfer-boun...@nmr.mgh.harvard.edu > on behalf of Douglas N Greve > > Sent: Tuesday, July 29, 2014 3:48 PM > To: freesurfer@nmr.mgh.harvard.edu > Subject: Re: [Freesurfer] MRI_glmfit-sim error > > I'm not sure how that could have happened. Did you run mri_glmfit > multiple times by any chance? > > On 07/29/2014 03:10 PM, Jon Alan Wieser wrote: >> >> I'm running a monte carlo sim and am getting an error: >> >> >> command line: >> >> >> mri_glmfit-sim \ >> --glmdir MTA_persistanceCP \ >> --sim mc-z 1000 1.3 mc-z.negative \ >> --sim-sign abs --cwpvalthresh 0.999 \ >> --overwrite >> >> >> >> output: >> >> cmdline mri_glmfit --y /Studies/MTA/qdec/MTA_persistanceCP/y.mgh >> --fsgd /Studies/MTA/qdec/MTA_persistanceCP/qdec.fsgd dods --glmdir >> /Studies/MTA/qdec/MTA_persistanceCP --surf fsaverage rh --label >> /Studies/MTA/fsaverage/label/rh.aparc.label --C >> /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Avg-Intercept-thickness.mat >> --C >> /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Diff-F-M-Intercept-thickness.mat >> SURFACE: fsaverage rh >> log file is MTA_persistanceCP/mc-z.negative.mri_glmfit-sim.log >> >> cd /Studies/MTA/qdec >> /Applications/freesurfer/bin/mri_glmfit-sim >> --glmdir MTA_persistanceCP --sim mc-z 1000 1.3 mc-z.negative >> --sim-sign abs --cwpvalthresh 0.999 --overwrite >> >> $Id: mri_glmfit-sim,v 1.36.2.5 2012/10/01 22:31:37 greve Exp $ >> Tue Jul 29 14:08:52 CDT 2014 >> Darwin psy-blackbird.ad.uwm.edu 10.8.0 Darwin Kernel Version 10.8.0: >> Tue Jun 7 16:32:41 PDT 2011; root:xnu-1504.15.3~1/RELEASE_X86_64 x86_64 >> wieser >> setenv SUBJECTS_DIR /Applications/freesurfer/subjects >> FREESURFER_HOME /Applications/freesurfer >> >> Original mri_glmfit command line: >> cmdline mri_glmfit --y /Studies/MTA/qdec/MTA_persistanceCP/y.mgh >> --fsgd /Studies/MTA/qdec/MTA_persistanceCP/qdec.fsgd dods --glmdir >> /Studies/MTA/qdec/MTA_persistanceCP --surf fsaverage rh --label >> /Studies/MTA/fsaverage/label/rh.aparc.label --C >> /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Avg-Intercept-thickness.mat >> --C >> /Studies/MTA/qdec/MTA_persistanceCP/contrasts/rh-Diff-F-M-Intercept-thickness.mat >> >> DoSim = 1 >> UseCache = 0 >> DoPoll = 0 >> DoPBSubmit = 0 >> DoBackground = 0 >> DiagCluster = 0 >> gd2mtx = dods >> fwhm = 14.370530 >> nSimPerJob = 1000 >> 1/1 Tue Jul 29 14:08:52 CDT 2014 >> mri_glmfit --y MTA_persistanceCP/y.mgh --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Avg-Intercept-thickness.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Avg-thickness-Gender-Cor.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-C-P-Cor-thickness-Gender.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-C-P-Intercept-thickness.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-Control-MJuser-Cor-thickness-Gender.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-Control-MJuser-Intercept-thickness.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-Diff-F-M-Intercept-thickness.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-X-ADHD_Persist-MJ_group-Cor-thickness-Gender.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/lh-X-ADHD_Persist-MJ_group-Intercept-thickness.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Avg-Intercept-thickness.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Avg-thickness-Gender-Cor.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-C-P-Cor-thickness-Gender.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Diff-C-P-Intercept-thickness.mtx >> --C >> MTA_persistanceCP/tmp.mri_glmfit-sim-68749/rh-Dif
Re: [Freesurfer] ERROR: dimension mismatch between input volume and seg
HI doug, thanks for getting back to me. I was able to solve the problem on my own. thanks again Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of Douglas N Greve Sent: Thursday, July 31, 2014 4:22 PM To: freesurfer@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] ERROR: dimension mismatch between input volume and seg Are you sure you are using orig.mgz when you run mri_vol2vol and not something like rawavg.mgz? You don't need to spec orig.mgz explicitly (it will use that by default) doug On 07/21/2014 04:51 PM, Jon Wieser wrote: > hi freesurfer experts > > I am compiling the FA segment stats for several subject > > I used > mri_vol2vol --mov fa.nii --reg register.dat --fstarg ../mri/orig.mgz > --interp nearest --o fa.anat.mgh > > then I used: > > mri_segstats --seg mri/wmparc.mgz --ctab > $FREESURFER_HOME/FreeSurferColorLUT.txt --i dti/fa.anat.mgh --sum dti/fa.stats > > > for some of my subjects, Iam getting the following error: > > > > mri_segstats --seg mri/wmparc.mgz --ctab > $FREESURFER_HOME/FreeSurferColorLUT.txt --i dti/fa.anat.mgh --sum dti/fa.stat > > $Id: mri_segstats.c,v 1.75.2.9 2013/02/16 00:09:33 greve Exp $ > cwd > cmdline mri_segstats --seg mri/wmparc.mgz --ctab > /Applications/freesurfer/FreeSurferColorLUT.txt --i dti/fa.anat.mgh --sum > dti/fa.stat > sysname Darwin > hostname psy-blackbird.ad.uwm.edu > machine x86_64 > user wieser > UseRobust 0 > Loading mri/wmparc.mgz > Loading dti/fa.anat.mgh > ERROR: dimension mismatch between input volume and seg >input 256 256 192 >seg 256 256 256 > > > > can you tell me how to fix this? > > thanks > Jon > > -- Douglas N. Greve, Ph.D. MGH-NMR Center gr...@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 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. ___ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
Re: [Freesurfer] LGI Topological Defect
Hi Tara try: recon-all -s -randomness -all Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of Tara Miskovich Sent: Friday, August 22, 2014 12:07 PM To: Freesurfer support list Subject: [Freesurfer] LGI Topological Defect Hi all, I am getting an error that seems common for people running LGI where it crashes due to a topological defect. I have run mris_euler_number and everything looks fine. Plus, I went through each slice and made sure the surfaces looked good. Any advice on any other steps I can take? I have already tried rerunning recon-all. Thank you! Tara ___ 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.
[Freesurfer] mri_glmfit-sim montecarlo analysis with mask
HI freesurfer experts We were wondering if it is possible to restrict the Monte Carlo analysis run by mri_glmfit-sim to a specific region fo the surface , instead of the whole surface, by using a mask or label to specify the ROI? I didn't see a --mask or --label option in mri_glmfit-sim Thank Jon ___ 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.
Re: [Freesurfer] mri_glmfit-sim montecarlo analysis with mask
thanks, but we are using qdec to do the inital analysis , not mri_glmfit Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of Douglas N Greve Sent: Thursday, September 11, 2014 9:54 AM To: freesurfer@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] mri_glmfit-sim montecarlo analysis with mask You do this by specifying a mask or label to mri_glmfit, then mri_glmfit-sim will automatically use this mask. Note that you have to run the simulation (ie, you cannot use --cache). In this case you may want to run mri_mcsim. See http://surfer.nmr.mgh.harvard.edu/fswiki/BuildYourOwnMonteCarlo doug On 09/11/2014 10:49 AM, Jon Alan Wieser wrote: > > HI freesurfer experts > > > We were wondering if it is possible to restrict the Monte Carlo > analysis run by mri_glmfit-sim to a specific region fo the surface , > instead of the whole surface, by using a mask or label to specify the ROI? > > I didn't see a --mask or --label option in mri_glmfit-sim > > Thank > > Jon > > > > ___ > 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 gr...@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 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. ___ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
Re: [Freesurfer] mri_glmfit-sim montecarlo analysis with mask
thanks, I'll try that Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of Douglas N Greve Sent: Thursday, September 11, 2014 10:03 AM To: freesurfer@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] mri_glmfit-sim montecarlo analysis with mask You'll have to use mri_glmfit to do this. QDEC is very limited when it comes to doing something special. QDEC will generate the fsgd file and contrast files for you. You can even look in the QDEC output folder for the mri_glmfit.log file which gives the mri_glmfit command. You'll just need to add a label to that. doug On 09/11/2014 10:59 AM, Jon Alan Wieser wrote: > thanks, but we are using qdec to do the inital analysis , not mri_glmfit > Jon > > > From: freesurfer-boun...@nmr.mgh.harvard.edu > on behalf of Douglas N Greve > > Sent: Thursday, September 11, 2014 9:54 AM > To: freesurfer@nmr.mgh.harvard.edu > Subject: Re: [Freesurfer] mri_glmfit-sim montecarlo analysis with mask > > You do this by specifying a mask or label to mri_glmfit, then > mri_glmfit-sim will automatically use this mask. Note that you have to > run the simulation (ie, you cannot use --cache). In this case you may > want to run mri_mcsim. See > http://surfer.nmr.mgh.harvard.edu/fswiki/BuildYourOwnMonteCarlo > > doug > > On 09/11/2014 10:49 AM, Jon Alan Wieser wrote: >> HI freesurfer experts >> >> >> We were wondering if it is possible to restrict the Monte Carlo >> analysis run by mri_glmfit-sim to a specific region fo the surface , >> instead of the whole surface, by using a mask or label to specify the ROI? >> >> I didn't see a --mask or --label option in mri_glmfit-sim >> >> Thank >> >> Jon >> >> >> >> ___ >> 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 > gr...@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 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. > > > ___ > 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 gr...@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 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
[Freesurfer] qdec and recon-all crashes
hi freesurfer folks, when I try to run qdec or recon-all, they crash recon-all -s MJ0001 -qcache if: Expression Syntax. qdec cd: Too many arguments. we have determined that because the subjects_directory name has spaces and ()'s in it, it is causing the two programs to crash echo $SUBJECTS_DIR /Users/wieser/Dropbox (UWM BraIN Lab)/ImagingSuite/Blackbird/MJMRI/MJ0001 I know that linux doesn't like spaces and ()'s in the directory name, and I usually avoid them, but we have recently started using dropbox to backup our data, in Dropbox is causing the spaces and ()'s to be in the directory name. Is there any way to make recon-all and qdec run in directories that have these characters in the directory name thanks Jon ___ 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.
Re: [Freesurfer] qdec and recon-all crashes
thanks Zeke, I have created the symbolic link. ln -s /Users/wieser/Dropbox\ \(UWM\ BraIN\ Lab\)/ImagingSuite/Blackbird/MJMRI DROPBOX_MJMRI I question is , when I cd into the symbolic link directory "DROPBOX_MJMRI" (which contains all to my subjects), and use qdec and recon-all to create new files and subdirectories in the linked directory, will those new files and directories be present in the original directory "/Users/wieser/Dropbox\ \(UWM\ BraIN\ Lab\)/ImagingSuite/Blackbird/MJMRI".the actual file, not just symbloic links. because dropbox is backing up the directory and dropbox does not like symbolic links thanks! From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of Z K Sent: Friday, November 14, 2014 2:13 PM To: Freesurfer support list Subject: Re: [Freesurfer] qdec and recon-all crashes The trick in the situation is to create a symbolic link. For example: $> cd /Users/wieser/ $> ln -s /Users/wieser/Dropbox\ (UWM\ BraIN\ Lab)/ImagingSuite/Blackbird/MJMRI/MJ0001 MJ0001 $> recon-all -s MJ0001 -qcache -Zeke On 11/14/2014 02:53 PM, Jon Alan Wieser wrote: > hi freesurfer folks, > > > when I try to run qdec or recon-all, they crash > > > > recon-all -s MJ0001 -qcache > > if: Expression Syntax. > > > > > qdec > cd: Too many arguments. > > > > we have determined that because the subjects_directory name has spaces > and ()'s in it, it is causing the two programs to crash > > echo $SUBJECTS_DIR > /Users/wieser/Dropbox (UWM BraIN Lab)/ImagingSuite/Blackbird/MJMRI/MJ0001 > > > I know that linux doesn't like spaces and ()'s in the directory name, > and I usually avoid them, but we have recently started using dropbox to > backup our data, in Dropbox is causing the spaces and ()'s to be in the > directory name. Is there any way to make recon-all and qdec run in > directories that have these characters in the directory name > > thanks > > Jon > > > > > ___ > 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. ___ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
Re: [Freesurfer] qdec and recon-all crashes
yes, I will test it. i'm kind of new to symbolic links. thanks! Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of Z K Sent: Friday, November 14, 2014 2:48 PM To: Freesurfer support list Subject: Re: [Freesurfer] qdec and recon-all crashes Yes, the directories and files will all exist under the Dropbox folder and will thus be backed up by Dropbox. But I suggest you test this for yourself and see. -Zeke On 11/14/2014 03:32 PM, Jon Alan Wieser wrote: > thanks Zeke, > > I have created the symbolic link. > > > ln -s /Users/wieser/Dropbox\ \(UWM\ BraIN\ > Lab\)/ImagingSuite/Blackbird/MJMRIDROPBOX_MJMRI > > > > I question is , when I cd into the symbolic link directory > "DROPBOX_MJMRI" (which contains all to my subjects), and use qdec > and recon-all to create new files and subdirectories in the linked > directory, will those new files and directories be present in the > original directory "/Users/wieser/Dropbox\ \(UWM\ BraIN\ > Lab\)/ImagingSuite/Blackbird/MJMRI".the actual file, not just > symbloic links. because dropbox is backing up the directory and > dropbox does not like symbolic links > > thanks! > > > From: > freesurfer-boun...@nmr.mgh.harvard.edu > on behalf of Z K > Sent: Friday, November 14, 2014 2:13 > PM To: Freesurfer support list Subject: Re: [Freesurfer] qdec and > recon-all crashes > > The trick in the situation is to create a symbolic link. For > example: > > $> cd /Users/wieser/ $> ln -s /Users/wieser/Dropbox\ (UWM\ BraIN\ > Lab)/ImagingSuite/Blackbird/MJMRI/MJ0001 MJ0001 $> recon-all -s > MJ0001 -qcache > > > -Zeke > > > On 11/14/2014 02:53 PM, Jon Alan Wieser wrote: >> hi freesurfer folks, >> >> >> when I try to run qdec or recon-all, they crash >> >> >> >> recon-all -s MJ0001 -qcache >> >> if: Expression Syntax. >> >> >> >> >> qdec cd: Too many arguments. >> >> >> >> we have determined that because the subjects_directory name has >> spaces and ()'s in it, it is causing the two programs to crash >> >> echo $SUBJECTS_DIR /Users/wieser/Dropbox (UWM BraIN >> Lab)/ImagingSuite/Blackbird/MJMRI/MJ0001 >> >> >> I know that linux doesn't like spaces and ()'s in the directory >> name, and I usually avoid them, but we have recently started using >> dropbox to backup our data, in Dropbox is causing the spaces and >> ()'s to be in the directory name. Is there any way to make >> recon-all and qdec run in directories that have these characters in >> the directory name >> >> thanks >> >> Jon >> >> >> >> >> ___ 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. > > > ___ 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 ___ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
Re: [Freesurfer] qdec and recon-all crashes
3.7 -11.1 17.1 105 postcentral 62.4048 66572 15.49 -33.17.1 27.2 42 caudalmiddlefrontal 7 -2.3036 37629 19.54 -19.7 26.0 -16.4 40 lateralorbitofrontal 82.2686 134209 22.64 -27.9 38.8 -8.7 41 lateralorbitofrontal 92.0927 112660 4.52 -13.9 -13.8 43.1 15 paracentral 10 -2.0050 39586 2.40-2.7 12.7 23.94 caudalanteriorcingulate ID not found ID not found ID not found ClusterNo Max VtxMax Size(mm2) TalX TalY TalZ NVtxs Annotation 23.2166 115393 93.03 -32.5 -87.8 -5.6 119 lateraloccipital ID not found ID not found ID not found ClusterNo Max VtxMax Size(mm2) TalX TalY TalZ NVtxs Annotation 32.6664 136940 64.28 -34.3 -4.6 -39.9 111 fusiform ID not found ID not found ID not found can you help with this? Thanks From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of Z K Sent: Friday, November 14, 2014 2:48 PM To: Freesurfer support list Subject: Re: [Freesurfer] qdec and recon-all crashes Yes, the directories and files will all exist under the Dropbox folder and will thus be backed up by Dropbox. But I suggest you test this for yourself and see. -Zeke On 11/14/2014 03:32 PM, Jon Alan Wieser wrote: > thanks Zeke, > > I have created the symbolic link. > > > ln -s /Users/wieser/Dropbox\ \(UWM\ BraIN\ > Lab\)/ImagingSuite/Blackbird/MJMRIDROPBOX_MJMRI > > > > I question is , when I cd into the symbolic link directory > "DROPBOX_MJMRI" (which contains all to my subjects), and use qdec > and recon-all to create new files and subdirectories in the linked > directory, will those new files and directories be present in the > original directory "/Users/wieser/Dropbox\ \(UWM\ BraIN\ > Lab\)/ImagingSuite/Blackbird/MJMRI".the actual file, not just > symbloic links. because dropbox is backing up the directory and > dropbox does not like symbolic links > > thanks! > > > From: > freesurfer-boun...@nmr.mgh.harvard.edu > on behalf of Z K > Sent: Friday, November 14, 2014 2:13 > PM To: Freesurfer support list Subject: Re: [Freesurfer] qdec and > recon-all crashes > > The trick in the situation is to create a symbolic link. For > example: > > $> cd /Users/wieser/ $> ln -s /Users/wieser/Dropbox\ (UWM\ BraIN\ > Lab)/ImagingSuite/Blackbird/MJMRI/MJ0001 MJ0001 $> recon-all -s > MJ0001 -qcache > > > -Zeke > > > On 11/14/2014 02:53 PM, Jon Alan Wieser wrote: >> hi freesurfer folks, >> >> >> when I try to run qdec or recon-all, they crash >> >> >> >> recon-all -s MJ0001 -qcache >> >> if: Expression Syntax. >> >> >> >> >> qdec cd: Too many arguments. >> >> >> >> we have determined that because the subjects_directory name has >> spaces and ()'s in it, it is causing the two programs to crash >> >> echo $SUBJECTS_DIR /Users/wieser/Dropbox (UWM BraIN >> Lab)/ImagingSuite/Blackbird/MJMRI/MJ0001 >> >> >> I know that linux doesn't like spaces and ()'s in the directory >> name, and I usually avoid them, but we have recently started using >> dropbox to backup our data, in Dropbox is causing the spaces and >> ()'s to be in the directory name. Is there any way to make >> recon-all and qdec run in directories that have these characters in >> the directory name >> >> thanks >> >> Jon >> >> >> >> >> ___ 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. > > > ___ 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 ___ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
[Freesurfer] mri_glmfit-sim sim-sign
hi please explain the differece between --sim-sign abs, neg, and pos ___ 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.
Re: [Freesurfer] mri_glmfit-sim sim-sign
yes I looked at mri_glmfit-sim -- help it says: --sim-sign sign : ,pos,neg and: 6. Select the threshold sign (--sim-sign). This is the sign of the threshold used to create the clusters for cluster-wise correction of multiple comparisons. Options are abs (unsigned), pos (positive), and neg (negative). freesurfer wiki says: --sim-sign sign sign is either abs (default), pos, or neg. pos/neg tell mri_glmfit to perform a one-tailed test. In this case, the contrast matrix can only have one row. we wanted to see all cluster, positvei or negative. should we be selecting "abs" for the sign? Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of Douglas N Greve Sent: Monday, November 24, 2014 11:02 AM To: freesurfer@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] mri_glmfit-sim sim-sign Have you looked at mri_glmfit-sim --help On 11/21/2014 01:51 PM, Jon Alan Wieser wrote: > > > hi > > please explain the differece between --sim-sign abs, neg, and pos > > > > ___ > 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 gr...@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 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. ___ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
[Freesurfer] longitudinal statistics LGI
HI freesurfer experts I have a question about the statistical analysis of longitudinal data. we have run our data through the longtudinal data processing stream. We are looking at the longitudinal effect on the LGI data We are looking at doing a Mixed effects analysis.our main Model Factor (Independent Variable) of interest is drug usage. we have continuous data as to the amount of drug usage. Can this variable be continous variable, or do we have to break it up into discrete levels of usage ( example, low, middle, high) Thanks Jon ___ 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.
Re: [Freesurfer] longitudinal statistics LGI
Jorge, We are interested in examining the impact of cannabis exposure (time-varying continuous variable) on local gyrification index over 3 time points (baseline, 18 month, 36 month)- so this is a time-varying random effect. I apologize in advance if these are student questions… we are novices here… From what you said previously, we would want to model intercept+time, vs intercept+cannabis use, vs intercept+time+ cannabis use. Vs. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time). We are trying to figure out how to do this in Freesurfer/Matlab using the Wiki (https://surfer.nmr.mgh.harvard.edu/fswiki/LinearMixedEffectsModels). There is a great example in there with AD/MCI groups, but none outlining an example focused on time-varying continuous variables. So with OUR question, would we organize the data as follows: Intercept Time Cannabis total (changes over time) Alcohol total (changes over time) Other Drug total (changes over time) Gender Age at baseline So, a few questions: 1)We need help writing the syntax for Matlab for testing the models (assuming linear trend was significant): a. intercept+time, vs b. intercept+cannabis use, vs c. intercept+time+ cannabis use. Vs. d. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time)… i. For example, this is the linear model for cortical thickness over time for the groups example: Yij = ß1 + ß2*tij + ß3*t²ij + ß4*sMCIi + ß5*sMCIi*tij + ß6*sMCIi*t²ij + ß7*cMCIi + ß8*cMCIi*tij + ß9*cMCIi*t²ij + ß10*ADi + ß11*ADi*tij + ß12*ADi*t²ij + ß13*E4i + ß14*E4i*tij + ß15*Genderi + ß16*BslAgei + ß17*Educationi + b1i + b2i*tij+ eij ii. This is the design matrix: [lhTh0,lhRe] = lme_mass_fit_EMinit(X,[1 2],Y,ni,lhcortex,3); 2)Is there a GUI available for setting up these models? (We are assuming there isn’t and that it is all matlab based.) 3)Once we test these models, is it correct that we open the spheres representing the liklihood ratio test results (corrected for multiple comparisons) and pick the “best” model based on the greatest #/size of significant clusters? Jon Jon Wieser Research Specialist UW-Milwaukee Psychology Department, Pearse Hall Rm 375 2441 East Hartford Ave Milwaukee, WI 53211 Phone: 414-229-7145 Fax: 414-229-5219 From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of jorge luis Sent: Tuesday, December 2, 2014 12:34 PM To: Freesurfer support list Subject: Re: [Freesurfer] longitudinal statistics LGI Hi Jon I guess that when you say “we have continuous data as to the amount of drug usage” you actually mean that the amount-of-drug-usage is a continuous variable that changes over time for each subject. So yes you can keep this variable as a continuous variable. In fact it can even be a random effect in your statistical model. You will need to select the model with the best combination of random effects : intercept+time vs intercept+amount-of-drug-usage vs intercept+time+amount-of-drug-usage. Actually one nice feature of the LME model implemented in freesurfer vs commonly used two-levels random effects models in neuroimaging is that you can include this type of longitudinal continuous variables in the model for the mean without requiring it be included in the model for the covariance (i.e included as a random effect). You just select the best subset of random effects as explained above. -Jorge De: Jon Alan Wieser Para: "freesurfer (freesurfer@nmr.mgh.harvard.edu)" Enviado: Martes 2 de diciembre de 2014 12:29 Asunto: [Freesurfer] longitudinal statistics LGI HI freesurfer experts I have a question about the statistical analysis of longitudinal data. we have run our data through the longtudinal data processing stream. We are looking at the longitudinal effect on the LGI data We are looking at doing a Mixed effects analysis.our main Model Factor (Independent Variable) of interest is drug usage. we have continuous data as to the amount of drug usage. Can this variable be continous variable, or do we have to break it up into discrete levels of usage ( example, low, middle, high) Thanks Jon ___ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu<mailto: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 contac
Re: [Freesurfer] longitudinal statistics LGI
HI Jorge, Thanks for your quick reply. What should we use for the contrast matrix? the freesurfer LME wiki has: CM.C = [zeros(3,5) [1 0 0 0 0 0 0;-1 0 0 1 0 0 0;0 0 0 -1 0 0 1] zeros(3,5)]; But I wasn't sure if that applies to our analyses. please excuse the naive questions, we are new to longitudinal LME analyses. Thanks again Jon From: jorge luis Sent: Wednesday, December 17, 2014 9:25 AM To: Freesurfer support list; Jon Alan Wieser Cc: Krista Lisdahl Medina; alicia.thomas@gmail.com Subject: Re: [Freesurfer] longitudinal statistics LGI Hi Jon We recommend to order the columns of your design matrix in the following way: First, the intercept term (which is a column of ones); second, the time covariate; third, any time-varying covariates (eg. cannabis use); fourth, the group covariates of interest (eg. a binary variable indicating whether the subject is a patient or control) and their interactions with the time-varying covariates; finally any other nuisance time-invariant covariate (eg. gender). So your design matrix is comprised by the following columns: 1. Intercept (a column of ones) 2. Time since baseline 3. cannabis use (time-varying if varies over time for each subject during the follow-up time) 4. alcohol use (time-varying if varies over time for each subject during the follow-up time) 5. drug use over time (time-varying if varies over time for each subject during the follow-up time) 6. gender 7. age at baseline There is no GUI for setting up the models. Here is an outline of the basic steps (with only three time points you shouldn't need more than two random effects): 1-Read your label eg.: lhcortex = fs_read_label('freesurfer/subjects/fsaverage/label/lh.cortex.label'); 2-Read the data file eg.: [lhY, lhmri] = fs_read_Y('lh.thickness.mgh'); 3-Fit a vertex-wise lme model with two random effects for the intercept term and time eg.: lhstats1 = lme_mass_fit_vw(X, [1 2], lhY, ni, lhcortex); 4-Fit a vertex-wise lme model with two random effects for the intercept term and cannabis use eg.: lhstats2 = lme_mass_fit_vw(X, [1 3], lhY, ni, lhcortex); And so on with other time-variying covariates... Now see which model fit produces the best lreml values across vertices in general and then: 4-Perform vertex-wise inferences using the winner model eg.: CM.C = [your contrast matrix]; F_lhstats = lme_mass_F(lhstats_winner, CM); 5-Save results eg.: fs_write_fstats(F_lhstats, lhmri,' sig.mgh', 'sig'); -Jorge ____ De: Jon Alan Wieser Para: jorge luis ; Freesurfer support list CC: Krista Lisdahl Medina ; "alicia.thomas@gmail.com" Enviado: Martes 16 de diciembre de 2014 15:24 Asunto: Re: [Freesurfer] longitudinal statistics LGI Jorge, We are interested in examining the impact of cannabis exposure (time-varying continuous variable) on local gyrification index over 3 time points (baseline, 18 month, 36 month)- so this is a time-varying random effect. I apologize in advance if these are student questions… we are novices here… From what you said previously, we would want to model intercept+time, vs intercept+cannabis use, vs intercept+time+ cannabis use. Vs. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time). We are trying to figure out how to do this in Freesurfer/Matlab using the Wiki (https://surfer.nmr.mgh.harvard.edu/fswiki/LinearMixedEffectsModels). There is a great example in there with AD/MCI groups, but none outlining an example focused on time-varying continuous variables. So with OUR question, would we organize the data as follows: Intercept Time Cannabis total (changes over time) Alcohol total (changes over time) Other Drug total (changes over time) Gender Age at baseline So, a few questions: 1)We need help writing the syntax for Matlab for testing the models (assuming linear trend was significant): a. intercept+time, vs b. intercept+cannabis use, vs c. intercept+time+ cannabis use. Vs. d. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time)… i. For example, this is the linear model for cortical thickness over time for the groups example: Yij = ß1 + ß2*tij + ß3*t²ij + ß4*sMCIi + ß5*sMCIi*tij + ß6*sMCIi*t²ij + ß7*cMCIi + ß8*cMCIi*tij + ß9*cMCIi*t²ij + ß10*ADi + ß11*ADi*tij + ß12*ADi*t²ij + ß13*E4i + ß14*E4i*tij + ß15*Genderi + ß16*BslAgei + ß17*Educationi + b1i + b2i*tij+ eij ii. This is the design matrix: [lhTh0,lhRe] = lme_mass_fit_EMinit(X,[1 2],Y,ni,lhcortex,3); 2)Is there a GUI available for setting up these models? (We are assuming there isn’t and that it is all matlab based.) 3)Once we test these models, is it correct that we open the spheres representing the liklihood ratio test resu
Re: [Freesurfer] longitudinal statistics LGI
Hi Jorge, One more newbie question. what's a good way to visualize the lhstats1.lreml values across the vertices? Thanks Jon From: jorge luis Sent: Wednesday, December 17, 2014 9:25 AM To: Freesurfer support list; Jon Alan Wieser Cc: Krista Lisdahl Medina; alicia.thomas@gmail.com Subject: Re: [Freesurfer] longitudinal statistics LGI Hi Jon We recommend to order the columns of your design matrix in the following way: First, the intercept term (which is a column of ones); second, the time covariate; third, any time-varying covariates (eg. cannabis use); fourth, the group covariates of interest (eg. a binary variable indicating whether the subject is a patient or control) and their interactions with the time-varying covariates; finally any other nuisance time-invariant covariate (eg. gender). So your design matrix is comprised by the following columns: 1. Intercept (a column of ones) 2. Time since baseline 3. cannabis use (time-varying if varies over time for each subject during the follow-up time) 4. alcohol use (time-varying if varies over time for each subject during the follow-up time) 5. drug use over time (time-varying if varies over time for each subject during the follow-up time) 6. gender 7. age at baseline There is no GUI for setting up the models. Here is an outline of the basic steps (with only three time points you shouldn't need more than two random effects): 1-Read your label eg.: lhcortex = fs_read_label('freesurfer/subjects/fsaverage/label/lh.cortex.label'); 2-Read the data file eg.: [lhY, lhmri] = fs_read_Y('lh.thickness.mgh'); 3-Fit a vertex-wise lme model with two random effects for the intercept term and time eg.: lhstats1 = lme_mass_fit_vw(X, [1 2], lhY, ni, lhcortex); 4-Fit a vertex-wise lme model with two random effects for the intercept term and cannabis use eg.: lhstats2 = lme_mass_fit_vw(X, [1 3], lhY, ni, lhcortex); And so on with other time-variying covariates... Now see which model fit produces the best lreml values across vertices in general and then: 4-Perform vertex-wise inferences using the winner model eg.: CM.C = [your contrast matrix]; F_lhstats = lme_mass_F(lhstats_winner, CM); 5-Save results eg.: fs_write_fstats(F_lhstats, lhmri,' sig.mgh', 'sig'); -Jorge ____ De: Jon Alan Wieser Para: jorge luis ; Freesurfer support list CC: Krista Lisdahl Medina ; "alicia.thomas@gmail.com" Enviado: Martes 16 de diciembre de 2014 15:24 Asunto: Re: [Freesurfer] longitudinal statistics LGI Jorge, We are interested in examining the impact of cannabis exposure (time-varying continuous variable) on local gyrification index over 3 time points (baseline, 18 month, 36 month)- so this is a time-varying random effect. I apologize in advance if these are student questions… we are novices here… From what you said previously, we would want to model intercept+time, vs intercept+cannabis use, vs intercept+time+ cannabis use. Vs. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time). We are trying to figure out how to do this in Freesurfer/Matlab using the Wiki (https://surfer.nmr.mgh.harvard.edu/fswiki/LinearMixedEffectsModels). There is a great example in there with AD/MCI groups, but none outlining an example focused on time-varying continuous variables. So with OUR question, would we organize the data as follows: Intercept Time Cannabis total (changes over time) Alcohol total (changes over time) Other Drug total (changes over time) Gender Age at baseline So, a few questions: 1)We need help writing the syntax for Matlab for testing the models (assuming linear trend was significant): a. intercept+time, vs b. intercept+cannabis use, vs c. intercept+time+ cannabis use. Vs. d. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time)… i. For example, this is the linear model for cortical thickness over time for the groups example: Yij = ß1 + ß2*tij + ß3*t²ij + ß4*sMCIi + ß5*sMCIi*tij + ß6*sMCIi*t²ij + ß7*cMCIi + ß8*cMCIi*tij + ß9*cMCIi*t²ij + ß10*ADi + ß11*ADi*tij + ß12*ADi*t²ij + ß13*E4i + ß14*E4i*tij + ß15*Genderi + ß16*BslAgei + ß17*Educationi + b1i + b2i*tij+ eij ii. This is the design matrix: [lhTh0,lhRe] = lme_mass_fit_EMinit(X,[1 2],Y,ni,lhcortex,3); 2)Is there a GUI available for setting up these models? (We are assuming there isn’t and that it is all matlab based.) 3)Once we test these models, is it correct that we open the spheres representing the liklihood ratio test results (corrected for multiple comparisons) and pick the “best” model based on the greatest #/size of significant clusters? Jon Jon Wieser Research Specialist UW-Milwaukee Psychology Department, Pearse Hall Rm 375 24
Re: [Freesurfer] longitudinal statistics LGI
HI Jorge What should we use for our Contrast Matrix (CM) ? Jon From: jorge luis Sent: Wednesday, December 17, 2014 9:25 AM To: Freesurfer support list; Jon Alan Wieser Cc: Krista Lisdahl Medina; alicia.thomas@gmail.com Subject: Re: [Freesurfer] longitudinal statistics LGI Hi Jon We recommend to order the columns of your design matrix in the following way: First, the intercept term (which is a column of ones); second, the time covariate; third, any time-varying covariates (eg. cannabis use); fourth, the group covariates of interest (eg. a binary variable indicating whether the subject is a patient or control) and their interactions with the time-varying covariates; finally any other nuisance time-invariant covariate (eg. gender). So your design matrix is comprised by the following columns: 1. Intercept (a column of ones) 2. Time since baseline 3. cannabis use (time-varying if varies over time for each subject during the follow-up time) 4. alcohol use (time-varying if varies over time for each subject during the follow-up time) 5. drug use over time (time-varying if varies over time for each subject during the follow-up time) 6. gender 7. age at baseline There is no GUI for setting up the models. Here is an outline of the basic steps (with only three time points you shouldn't need more than two random effects): 1-Read your label eg.: lhcortex = fs_read_label('freesurfer/subjects/fsaverage/label/lh.cortex.label'); 2-Read the data file eg.: [lhY, lhmri] = fs_read_Y('lh.thickness.mgh'); 3-Fit a vertex-wise lme model with two random effects for the intercept term and time eg.: lhstats1 = lme_mass_fit_vw(X, [1 2], lhY, ni, lhcortex); 4-Fit a vertex-wise lme model with two random effects for the intercept term and cannabis use eg.: lhstats2 = lme_mass_fit_vw(X, [1 3], lhY, ni, lhcortex); And so on with other time-variying covariates... Now see which model fit produces the best lreml values across vertices in general and then: 4-Perform vertex-wise inferences using the winner model eg.: CM.C = [your contrast matrix]; F_lhstats = lme_mass_F(lhstats_winner, CM); 5-Save results eg.: fs_write_fstats(F_lhstats, lhmri,' sig.mgh', 'sig'); -Jorge ____ De: Jon Alan Wieser Para: jorge luis ; Freesurfer support list CC: Krista Lisdahl Medina ; "alicia.thomas@gmail.com" Enviado: Martes 16 de diciembre de 2014 15:24 Asunto: Re: [Freesurfer] longitudinal statistics LGI Jorge, We are interested in examining the impact of cannabis exposure (time-varying continuous variable) on local gyrification index over 3 time points (baseline, 18 month, 36 month)- so this is a time-varying random effect. I apologize in advance if these are student questions… we are novices here… From what you said previously, we would want to model intercept+time, vs intercept+cannabis use, vs intercept+time+ cannabis use. Vs. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time). We are trying to figure out how to do this in Freesurfer/Matlab using the Wiki (https://surfer.nmr.mgh.harvard.edu/fswiki/LinearMixedEffectsModels). There is a great example in there with AD/MCI groups, but none outlining an example focused on time-varying continuous variables. So with OUR question, would we organize the data as follows: Intercept Time Cannabis total (changes over time) Alcohol total (changes over time) Other Drug total (changes over time) Gender Age at baseline So, a few questions: 1)We need help writing the syntax for Matlab for testing the models (assuming linear trend was significant): a. intercept+time, vs b. intercept+cannabis use, vs c. intercept+time+ cannabis use. Vs. d. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time)… i. For example, this is the linear model for cortical thickness over time for the groups example: Yij = ß1 + ß2*tij + ß3*t²ij + ß4*sMCIi + ß5*sMCIi*tij + ß6*sMCIi*t²ij + ß7*cMCIi + ß8*cMCIi*tij + ß9*cMCIi*t²ij + ß10*ADi + ß11*ADi*tij + ß12*ADi*t²ij + ß13*E4i + ß14*E4i*tij + ß15*Genderi + ß16*BslAgei + ß17*Educationi + b1i + b2i*tij+ eij ii. This is the design matrix: [lhTh0,lhRe] = lme_mass_fit_EMinit(X,[1 2],Y,ni,lhcortex,3); 2)Is there a GUI available for setting up these models? (We are assuming there isn’t and that it is all matlab based.) 3)Once we test these models, is it correct that we open the spheres representing the liklihood ratio test results (corrected for multiple comparisons) and pick the “best” model based on the greatest #/size of significant clusters? Jon Jon Wieser Research Specialist UW-Milwaukee Psychology Department, Pearse Hall Rm 375 2441 East Hartford Ave Milwaukee, WI 53211 Phone: 414-229-7145 Fax
[Freesurfer] Fw: longitudinal statistics LGI
Hi Jorge, Following your instructions, so far we have done the following: 1-Read your label lhcortex = fs_read_label('freesurfer/subjects/fsaverage/label/lh.cortex.label'); 2-Read the data file [lhY, lhmri] = fs_read_Y('lh.thickness.mgh'); 3-Fit a vertex-wise lme model with two random effects for the intercept term and time eg.: lhstats1 = lme_mass_fit_vw(X, [1 2], lhY, ni, lhcortex); 4-Fit a vertex-wise lme model with two random effects for the intercept term and cannabis use eg.: lhstats2 = lme_mass_fit_vw(X, [1 3], lhY, ni, lhcortex); lhstats3 = lme_mass_fit_vw(X, [1 2 6], lhY, ni, lhcortex); %intercept_time_gender lhstats4 = lme_mass_fit_vw(X, [1 2 7], lhY, ni, lhcortex); %intercept_time_age lhstats5 = lme_mass_fit_vw(X, [1 2 3 6 ], lhY, ni, lhcortex); %intercept_time_cannabis_gender We displayed the lREML data on the surface models in matlab. In some cases,(when there were 3 or more effects ( i.e. 1 2 6) ) the lreml values had real and imaginary values, so I displayed the ABS value of the lreml We need to know the following: 1. How do we model this: Intercept, time, age, gender, Alcohol, other drugs vs. Intercept, time, age, Gender, Alcohol, Other drug, cannabis 2. Correct for multiple comparisons 3. Open these in Freesurfer, significance maps using tksurfer ( P < 0.05) Is it only visual, or is there a significance test between the two models 4. How do we get a map that demonstrates the unique effect of cannabis 5. What Contrast matrix do we use for the LME_mass_F program Thanks Jon From: jorge luis Sent: Wednesday, December 17, 2014 9:25 AM To: Freesurfer support list; Jon Alan Wieser Cc: Krista Lisdahl Medina; alicia.thomas@gmail.com Subject: Re: [Freesurfer] longitudinal statistics LGI Hi Jon We recommend to order the columns of your design matrix in the following way: First, the intercept term (which is a column of ones); second, the time covariate; third, any time-varying covariates (eg. cannabis use); fourth, the group covariates of interest (eg. a binary variable indicating whether the subject is a patient or control) and their interactions with the time-varying covariates; finally any other nuisance time-invariant covariate (eg. gender). So your design matrix is comprised by the following columns: 1. Intercept (a column of ones) 2. Time since baseline 3. cannabis use (time-varying if varies over time for each subject during the follow-up time) 4. alcohol use (time-varying if varies over time for each subject during the follow-up time) 5. drug use over time (time-varying if varies over time for each subject during the follow-up time) 6. gender 7. age at baseline There is no GUI for setting up the models. Here is an outline of the basic steps (with only three time points you shouldn't need more than two random effects): 1-Read your label eg.: lhcortex = fs_read_label('freesurfer/subjects/fsaverage/label/lh.cortex.label'); 2-Read the data file eg.: [lhY, lhmri] = fs_read_Y('lh.thickness.mgh'); 3-Fit a vertex-wise lme model with two random effects for the intercept term and time eg.: lhstats1 = lme_mass_fit_vw(X, [1 2], lhY, ni, lhcortex); 4-Fit a vertex-wise lme model with two random effects for the intercept term and cannabis use eg.: lhstats2 = lme_mass_fit_vw(X, [1 3], lhY, ni, lhcortex); And so on with other time-variying covariates... Now see which model fit produces the best lreml values across vertices in general and then: 4-Perform vertex-wise inferences using the winner model eg.: CM.C = [your contrast matrix]; F_lhstats = lme_mass_F(lhstats_winner, CM); 5-Save results eg.: fs_write_fstats(F_lhstats, lhmri,' sig.mgh', 'sig'); -Jorge De: Jon Alan Wieser Para: jorge luis ; Freesurfer support list CC: Krista Lisdahl Medina ; "alicia.thomas@gmail.com" Enviado: Martes 16 de diciembre de 2014 15:24 Asunto: Re: [Freesurfer] longitudinal statistics LGI Jorge, We are interested in examining the impact of cannabis exposure (time-varying continuous variable) on local gyrification index over 3 time points (baseline, 18 month, 36 month)- so this is a time-varying random effect. I apologize in advance if these are student questions… we are novices here… From what you said previously, we would want to model intercept+time, vs intercept+cannabis use, vs intercept+time+ cannabis use. Vs. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time). We are trying to figure out how to do this in Freesurfer/Matlab using the Wiki (https://surfer.nmr.mgh.harvard.edu/fswiki/LinearMixedEffectsModels). There is a great example in there with AD/MCI groups, but none outlining an example focused on time-varying continuous variables. So with OUR question, would we organize the data as follows:
Re: [Freesurfer] longitudinal statistics LGI
HI Jorge, how do you determine the number of rows(L) in the contrast matrix? so if we want to test the effect of cannabis usage, which is the third column in our design matrix : would our contrast matrix be something like: CM.C = [0 0 1 0 0 0 0] or CM.C = [0 0 1 0 0 0 0; 0 0 -1 0 0 0 0; 0 0 0 0 0 0 0] our design matrix: 1. Intercept (a column of ones) 2. Time since baseline 3. cannabis use (time-varying if varies over time for each subject during the follow-up time) 4. alcohol use (time-varying if varies over time for each subject during the follow-up time) 5. drug use over time (time-varying if varies over time for each subject during the follow-up time) 6. gender 7. age at baseline Jon From: freesurfer-boun...@nmr.mgh.harvard.edu on behalf of jorge luis Sent: Saturday, January 3, 2015 1:50 PM To: Freesurfer support list Subject: Re: [Freesurfer] longitudinal statistics LGI Hi Jon Your contrast matrix depends on the hypothesis you want to test. Contrast matrices for lme are specified in the same way as for the General Linear Model. Nothing different here. It's a matrix of L rows where L>=1 and the same number of columns as the number of fixed effects (population parameters) in your model. Best -Jorge ____ De: Jon Alan Wieser Para: jorge luis CC: "freesurfer (freesurfer@nmr.mgh.harvard.edu)" Enviado: Domingo 28 de diciembre de 2014 10:23 Asunto: Re: [Freesurfer] longitudinal statistics LGI HI Jorge What should we use for our Contrast Matrix (CM) ? Jon From: jorge luis Sent: Wednesday, December 17, 2014 9:25 AM To: Freesurfer support list; Jon Alan Wieser Cc: Krista Lisdahl Medina; alicia.thomas@gmail.com Subject: Re: [Freesurfer] longitudinal statistics LGI Hi Jon We recommend to order the columns of your design matrix in the following way: First, the intercept term (which is a column of ones); second, the time covariate; third, any time-varying covariates (eg. cannabis use); fourth, the group covariates of interest (eg. a binary variable indicating whether the subject is a patient or control) and their interactions with the time-varying covariates; finally any other nuisance time-invariant covariate (eg. gender). So your design matrix is comprised by the following columns: 1. Intercept (a column of ones) 2. Time since baseline 3. cannabis use (time-varying if varies over time for each subject during the follow-up time) 4. alcohol use (time-varying if varies over time for each subject during the follow-up time) 5. drug use over time (time-varying if varies over time for each subject during the follow-up time) 6. gender 7. age at baseline There is no GUI for setting up the models. Here is an outline of the basic steps (with only three time points you shouldn't need more than two random effects): 1-Read your label eg.: lhcortex = fs_read_label('freesurfer/subjects/fsaverage/label/lh.cortex.label'); 2-Read the data file eg.: [lhY, lhmri] = fs_read_Y('lh.thickness.mgh'); 3-Fit a vertex-wise lme model with two random effects for the intercept term and time eg.: lhstats1 = lme_mass_fit_vw(X, [1 2], lhY, ni, lhcortex); 4-Fit a vertex-wise lme model with two random effects for the intercept term and cannabis use eg.: lhstats2 = lme_mass_fit_vw(X, [1 3], lhY, ni, lhcortex); And so on with other time-variying covariates... Now see which model fit produces the best lreml values across vertices in general and then: 4-Perform vertex-wise inferences using the winner model eg.: CM.C = [your contrast matrix]; F_lhstats = lme_mass_F(lhstats_winner, CM); 5-Save results eg.: fs_write_fstats(F_lhstats, lhmri,' sig.mgh', 'sig'); -Jorge De: Jon Alan Wieser Para: jorge luis ; Freesurfer support list CC: Krista Lisdahl Medina ; "alicia.thomas@gmail.com" Enviado: Martes 16 de diciembre de 2014 15:24 Asunto: Re: [Freesurfer] longitudinal statistics LGI Jorge, We are interested in examining the impact of cannabis exposure (time-varying continuous variable) on local gyrification index over 3 time points (baseline, 18 month, 36 month)- so this is a time-varying random effect. I apologize in advance if these are student questions… we are novices here… From what you said previously, we would want to model intercept+time, vs intercept+cannabis use, vs intercept+time+ cannabis use. Vs. intercept+time+ cannabis use.+covariates (alcohol use over time, gender, age, drug use over time). We are trying to figure out how to do this in Freesurfer/Matlab using the Wiki (https://surfer.nmr.mgh.harvard.edu/fswiki/LinearMixedEffectsModels). There is a great example in there with AD/MCI groups, but none outlining an example focused on time-varying continuous variables. So with OUR question, would we organize the data as follows: Intercept Time Cannabis tot