Hi, Doug. Thanks a lot! The command would look like this: mri_glmfit-sim --glmdir lh.thickness.Sch.glmdir --sim mc-z 10000 2 teste --sim-sign abs --overwrite --cache 1.3 abs It takes only a few seconds to run. I have a few questions about how to run it: 1) How the single entry for each subject look like in the FSGD file?
2) How to define the voxel/vertex-wise used to define clusters (after —sim, -log10( p)), and the voxel-wise threshold for the —cache option? What is the difference between them? Thanks again, Pedro Rosa. On Monday, April 14, 2014 at 3:29 PM, Douglas N Greve wrote: > > On 04/14/2014 10:35 AM, Pedro Rosa wrote: > > Dear Doug and Jorge, > > I tried what you suggested and I think it work, although I have some > > concerns. > > I am working with a longitudinal study with two time-points for all > > subjects, three categorical variables (group, substance abuse / > > dependence and gender) and three continuous variables (interval > > between scans, age and medication intake). > > I generated a contrast with intercept + 7 betas for the LME, ran it > > without any problem and saved the sig.mgh using > > fs_write_fstats(F_lhstats,mri,’sig.mgh’,’sig’). > > For the mri_glmfit I entered the same output from mri_surf2surf I used > > for the LME (smoothed at 10mm), but I did not know how exactly to > > enter the categorical and continuous variables, or which contrast to use. > > > > I would do it as a paired-test (see the wiki). You may have to re-run > mris_preproc with the --paired-diff flag, then smooth by 10mm. Use this > as the input to mri_glmfit. Set up the FSGD with the categorical and > continuous variables (note that the FSGD file will have only a single > entry per subject). Create your contrasts and run mri_glmfit. Overwrite > the sig.mgh with the one from LME. Then run mri_glmfit-sim with the > --cache option (not permutation) > > I don't know what your contrast of interest is, so I can't help you > there. In the end, it does not matter because you are overwriting the > sig map anyway. You just need a contrast as a place holder. > > doug > > > The commmand was: mri_glmfit —y pval.mgh —sim perm 10000 0.05 sch > > > > I just tested creating a matrix with 24 columns > > (Nclasses*(Nvariables+1) as suggested for DODS). > > Afterwards I ran the mri_glmfit-sim (mri_glmfit-sim --glmdir > > Sch-glmdir --sim mc-full 5 2 teste --sim-sign abs, and it finished > > apparently without errors. > > I attached the logs for both mri_glmfit and mri_glmfit-sim. > > > > That said, I have the following questions: > > > > 1) What does the FWHM procedure does? > > 2) How should I decide which contrast to test if the mri_glmfit does > > not consider the longitudinal design? > > 3) Will the mri_glmfit-sim consider only the FMHM output from > > mri_glmfit and sig.mgh from the LME, or also other outputs from the > > mri_glmfit? > > 4) Does the FWHM rely only on the images, and not on variables and > > contrasts? > > > > Thank you very much! > > Pedro Rosa. > > > > On Monday, March 31, 2014 at 10:53 PM, Pedro Rosa wrote: > > > > > Thanks, Doug! > > > Should I run the mri_preproc and and smooth the output using > > > mri_surf2surf with, let’s say, 10mm, and than run the LME normally in > > > MatLab? > > > Would this be problematic with a different smoothing procedure in > > > mri_glmfit? > > > How will mri_glmfit deal with the longitudinal design? Does this > > > matter, or the FWHM would only be estimated on a average image of all > > > time-points for all subjects? > > > Regards, > > > Pedro Rosa. > > > > > > On Sunday, March 30, 2014 at 3:51 PM, Douglas Greve wrote: > > > > > > > > > > > I think I would just run mri_glmfit on your data to get the proper > > > > directly structure and estimate of FWHM, then copy the sig file from > > > > the mixed fx analysis into the glmfit folder for one of the > > > > contrasts. Then run mri_glmfit-sim. > > > > > > > > doug > > > > > > > > > > > > On 3/29/14 10:29 AM, Pedro Rosa wrote: > > > > > Dear Doug and Jorge, > > > > > Thank you very much for your help. > > > > > I found another message in the list > > > > > (https://mail.nmr.mgh.harvard.edu/pipermail//freesurfer/2013-November/034649.html) > > > > > > > > > > in which you suggested a way of using MC in mri_glmfit-sim by > > > > > creating “fake files”, which would not be read by the script. In > > > > > this case, only the simulation would be run, and not the full > > > > > statistics. The command would be something like this: > > > > > - mri_glmfit-sim --glmdir $SUBJECTS_DIR --sim mc-full 5 2 teste > > > > > --sim-sign abs > > > > > I created a “fake” mri_glmfit.log, fwhm.dat and mask.mgh files as > > > > > suggested by the older post. This would be fine, I believe, if only > > > > > sig.mgh is read by the script. > > > > > However, I get this message after running the command: > > > > > > > > > > [server:Long-T0-T2-Posproc/Vertex/Sch] pedrogomesrosa% > > > > > mri_glmfit-sim --glmdir $SUBJECTS_DIR --sim mc-full 5 2 teste > > > > > --sim-sign abs > > > > > > > > > > if: Expression Syntax. > > > > > > > > > > > > > > > Is it possible to do what I am trying to do? Does the residual > > > > > errors at each location included in the sig.mgh, and, if necessary, > > > > > how to compute it into image FWHM? > > > > > > > > > > Regards, > > > > > > > > > > Pedro Rosa. > > > > > > > > > > On Friday, March 28, 2014 at 2:38 PM, Douglas N Greve wrote: > > > > > > > > > > > Jorge, do you output the FWHM? > > > > > > doug > > > > > > > > > > > > On 03/27/2014 03:14 PM, jorge luis wrote: > > > > > > > Hi Pedro > > > > > > > > > > > > > > Sorry, right now the only multiple comparisons corrections > > > > > > > implemented > > > > > > > in lme are the original Benjamini and Hochberg (1995) FDR > > > > > > > procedure > > > > > > > (lme_mass_FDR) and a more recent and powerful two-stage FDR > > > > > > > procedure > > > > > > > (lme_mass_FDR2): > > > > > > > > > > > > > > Benjamini, Y., Krieger, A.M., Yekutieli, D. (2006). Adaptive > > > > > > > linear > > > > > > > step-up procedures that control the false discovery rate. > > > > > > > Biometrika, > > > > > > > 93, 491-507. > > > > > > > > > > > > > > In my experience, this procedure is as powerful to detect effects > > > > > > > in > > > > > > > neuroimage data as alternative corrections with strong control of > > > > > > > > > > > > > > the > > > > > > > family-wise error rate (FWE). However it would be great if we > > > > > > > could > > > > > > > use an implementation of any multiple comparisons correction with > > > > > > > strong control of the FWE (MC, RFT, ect...) for lme (FDR > > > > > > > procedures > > > > > > > only provide weak control). The residual errors at each location > > > > > > > required to compute an estimate of the image FWHM can be obtained > > > > > > > > > > > > > > from > > > > > > > the lme output. But an actual FWHM estimate is not currently > > > > > > > saved. > > > > > > > > > > > > > > Best > > > > > > > -Jorge > > > > > > > > > > > > > > > > > > > > > El Martes 25 de marzo de 2014 8:15, Pedro Rosa > > > > > > > <pedrogomesr...@gmail.com (mailto:pedrogomesr...@gmail.com) > > > > > > > <mailto:pedrogomesr...@gmail.com>> > > > > > > > escribió: > > > > > > > > > > > > > > Dear Doug, > > > > > > > Thank you very much! > > > > > > > I will try what you suggested, although I am not sure if Jorge's > > > > > > > stream outputs the FMHM, or if I would need to run the statistics > > > > > > > from the beggining using in the terminal, and not in MatLab. > > > > > > > Do you think Jorge could comment on this issue? > > > > > > > Regards, > > > > > > > Pedro Rosa. > > > > > > > > > > > > > > On Mar 24, 2014, at 12:44 PM, Douglas Greve > > > > > > > <gr...@nmr.mgh.harvard.edu (mailto:gr...@nmr.mgh.harvard.edu) > > > > > > > <mailto:gr...@nmr.mgh.harvard.edu> > > > > > > > <mailto:gr...@nmr.mgh.harvard.edu>> wrote: > > > > > > > > > > > > > > > > > > > > > In theory, it should be possible. I have not used Jorge's stream, > > > > > > > so I > > > > > > > don't know that much about it. Does it save an estimate of the > > > > > > > FWHM? If > > > > > > > so, then you can run mri_surfcluster passing it the p-value (ie, > > > > > > > -log10(p)) map, the FWHM, the mask, and a voxel-wise threshold. > > > > > > > This is > > > > > > > what mri_glmfit-sim does, so you might check that script for > > > > > > > mri_surfcluster command line options > > > > > > > > > > > > > > doug > > > > > > > > > > > > > > > > > > > > > > On 3/22/14 11:03 PM, Pedro Rosa wrote: > > > > > > > > Dear list, > > > > > > > > I ran the recon-all and the Freesurfer 5.1 longitudinal pipeline > > > > > > > > > > > > > > > > > > > > > > in a structural MRI dataset and I would like to use Monte Carlo as > > > > > > > the method for correction for multiple comparisons. However, the > > > > > > > longitudinal LME tutorial includes only FDR correction > > > > > > > (lme_mass_FDR2). > > > > > > > > Is it possible to use Monte Carlo correction for longitudinal > > > > > > > > > > > > > > data? Can I input the outputs from MatLab (fstats = > > > > > > > lme_mass_F(?h,CM): stats.F / pval / sgn / df) into mri_glmfit and > > > > > > > then run Monte Carlo? > > > > > > > > If not, do you have any other suggestions of how I use Monte > > > > > > > > > > > > > > Carlo in longitudinal analyses? > > > > > > > > Thanks in advance, > > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > > > > Freesurfer mailing list > > > > > > > Freesurfer@nmr.mgh.harvard.edu > > > > > > > (mailto:Freesurfer@nmr.mgh.harvard.edu) > > > > > > > <mailto: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 contact the > > > > > > > sender and properly > > > > > > > dispose of the e-mail. > > > > > > > > > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > > > > Freesurfer mailing list > > > > > > > Freesurfer@nmr.mgh.harvard.edu > > > > > > > (mailto:Freesurfer@nmr.mgh.harvard.edu) > > > > > > > <mailto:Freesurfer@nmr.mgh.harvard.edu> > > > > > > > <mailto:Freesurfer@nmr.mgh.harvard.edu> > > > > > > > https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > > > > Freesurfer mailing list > > > > > > > Freesurfer@nmr.mgh.harvard.edu > > > > > > > (mailto:Freesurfer@nmr.mgh.harvard.edu) > > > > > > > <mailto: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 (mailto:gr...@nmr.mgh.harvard.edu) > > > > > > <mailto: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 > > > > > > (http://www.nmr.mgh.harvard.edu/facility/filedrop/index.html) > > > > > > <http://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 > > > > > > (mailto:Freesurfer@nmr.mgh.harvard.edu) > > > > > > <mailto:Freesurfer@nmr.mgh.harvard.edu> > > > > > > https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > > Freesurfer mailing list > > > > > Freesurfer@nmr.mgh.harvard.edu > > > > > (mailto:Freesurfer@nmr.mgh.harvard.edu) > > > > > <mailto:Freesurfer@nmr.mgh.harvard.edu> > > > > > https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer > > > > > > > > > > > > > > > > > _______________________________________________ > > > > Freesurfer mailing list > > > > Freesurfer@nmr.mgh.harvard.edu (mailto: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 contact the sender > > > > and properly > > > > dispose of the e-mail. > > > > > > > > > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > Freesurfer mailing list > > Freesurfer@nmr.mgh.harvard.edu (mailto: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 (mailto: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 > (http://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 (mailto: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.