Re: [Freesurfer] Contrast file to be used in mri_glimfit

2020-04-23 Thread Lab of Autism and Developmental Neuroscience, Lab of Autism and Developmental Neuroscience
External Email - Use Caution

I tried running mri_glmfit and this error is occurring -

WARNING: gdfReadV1: class B, is defined but not used.

INFO: DeMeanFlag keyword not found, DeMeaning will NOT be done.

Continuous Variable Means (all subjects)

0 ,,,Gender,Age,AQ_Top_Quart nan nan

Class Means of each Continuous Variable

1 B,  nan

2 NB,  nan

INFO: gd2mtx_method is dods

Reading source surface
/Applications/freesurfer/BAP/group_analysis_data/qdec/fsaverage/surf/lh.–-glmdir

MRISread(/Applications/freesurfer/BAP/group_analysis_data/qdec/fsaverage/surf


This is probably related to some error in my .mtx file.


Thank you,

Alex Job

On Fri, Apr 24, 2020 at 12:31 AM Lab of Autism and Developmental
Neuroscience, Lab of Autism and Developmental Neuroscience <
l...@email.gwu.edu> wrote:

> Dear Freesurfer experts,
>
> I am a little bit confused on how I should construct my .mtx file to be
> used in mri_glmfit. The following variables are what I have used in my fsgd
> file:
> GroupDescriptorFile 1
> Title Study
> Class B
> Class NB
> Variables ,,,Gender,Age
> Input, Sub_ID,NB,F,71
> Input, Sub_ID, B, F, 80
>
> Please let me know if you need more information on my work. Thank you!
>
> All the best,
> Alex Job
>
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

[Freesurfer] Contrast file to be used in mri_glimfit

2020-04-23 Thread Lab of Autism and Developmental Neuroscience, Lab of Autism and Developmental Neuroscience
External Email - Use Caution

Dear Freesurfer experts,

I am a little bit confused on how I should construct my .mtx file to be
used in mri_glmfit. The following variables are what I have used in my fsgd
file:
GroupDescriptorFile 1
Title Study
Class B
Class NB
Variables ,,,Gender,Age
Input, Sub_ID,NB,F,71
Input, Sub_ID, B, F, 80

Please let me know if you need more information on my work. Thank you!

All the best,
Alex Job
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Generating Surfaces Meshes

2020-04-23 Thread Peter, Jonah
Hi Bruce,

The issue is that I want the surface mesh itself to reflect the correct
(partial volume corrected) volume as I will be simulating the passage of
high energy particles through it. Do you think it would suffice to take the
(smoothed) mesh and simply scale its volume in an application like blender?
My thinking is that the partial volume effects are probably isotropic so a
uniform scaling would leave the geometry unchanged.

Best,
Jonah

On Thu, Apr 23, 2020 at 9:53 PM Bruce Fischl 
wrote:

> HI Jonah
>
> it depends how you compute volume. mris_volume for example will compute
> the
> volume of the interior without any partial volume correction.
>
> And yes, I would expect you want to smooth the surface a bit. You might
> try
> the Taubin smoothing built into freeview as it won't shrink the surface,
> but you can also try mris_smooth
>
> cheers
> Bruce
>
>
> On Thu, 23 Apr 2020, Peter, Jonah wrote:
>
> > Hi Bruce,
> > I tried mri_tessellate which worked well in that the surface seems to
> follow the aseg projections
> > exactly. Does the volume of this mesh account for partial volume
> effects? Also, is there a need to run
> > mri_pretess or some sort of smoothing procedure?
> >
> > For reference, what I am trying to do is import these surface meshes
> into a Geant4 simulation for proton
> > therapy, and want to make sure I'm using as realistic geometry as
> possible. Ideally I'd be able to
> > generate a mesh for the whole brain as well as individual segmentations.
> >
> > Thanks again for your help,
> > Jonah
> >
> > On Thu, Apr 23, 2020 at 5:50 PM Bruce Fischl 
> wrote:
> >   no, they are definitely not negligible. It depends on structure
> geometry,
> >   but I bet for something like the hippocampus a large fraction of
> voxels in
> >   it are partial volumed.
> >
> >   You can use mri_mc or mri_tessellate to generate a mesh. It will
> be closed
> >   but may not have a simple topology
> >
> >   On Thu, 23 Apr 2020, Peter, Jonah
> >   wrote:
> >
> >   > Hi all,
> >   > Thanks for the response. I'm familiar with partial volume
> effects within the context of
> >   PET imaging, but
> >   > wouldn't you expect these effects to be negligible in MRI for
> structures on the order of
> >   mm?
> >   >
> >   > With respect to the mesh type, I'd like to get closed meshes for
> each
> >   segmentation/parcellation.
> >   >
> >   > Is there a way to do this in freesurfer?
> >   >
> >   > On Thu, Apr 23, 2020 at 10:44 AM Bruce Fischl <
> fis...@nmr.mgh.harvard.edu> wrote:
> >   >   Hi Jonah
> >   >
> >   >   when we compute volumes we typically use a partial-volume
> model, which we
> >   >   have found improves accuracy and repeatability. That may
> be the source of
> >   >   your discrepancy
> >   >
> >   >   cheers
> >   >   Bruce
> >   >   On Wed, 22 Apr 2020, Peter, Jonah wrote:
> >   >
> >   >   > Hello,
> >   >   > I'm trying to generate surface meshes for different
> brain regions that can
> >   >   > be imported into a software like MeshLab or Blender
> (i.e. .STL, .PLY, .OBJ,
> >   >   > etc.). I ran recon-all on my T1 images, and the
> parcellation/segmentation
> >   >   > looks fine. However, I noticed that when I imported this
> data into 3DSlicer,
> >   >   > the volumes of these regions did not match the volumes
> in the aseg.stats
> >   >   > file. In some cases, the differences were quite
> substantial. I tried
> >   >   > removing all smoothing filters in 3DSlicer but the
> outcome was the same.
> >   >   >
> >   >   > Do you know what could be going wrong here?
> Alternatively, is there an
> >   >   > easier way to generate surface meshes from the aparc or
> aseg atlases?
> >   >   >
> >   >   > I'm using the ICBM 2009c Nonlinear Asymmetric
> >   >   > template (http://nist.mni.mcgill.ca/?p=904) as a
> generic brain volume
> >   >   > (though alternative suggestions are welcome).
> >   >   >
> >   >   > Thanks!
> >   >   > Jonah
> >   >   >
> >   >   > --
> >   >   > Jonah PeterGraduate Student in The Biophysics
> ProgramHarvard University
> >   >   > P: 646-306-0848
> >   >   > E: jonahpe...@g.harvard.edu
> >   >   >
> >   >   >___
> >   >   Freesurfer mailing list
> >   >   Freesurfer@nmr.mgh.harvard.edu
> >   >
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
> >   >
> >   >
> >   >
> >   > --
> >   > Jonah PeterGraduate Student in The Biophysics ProgramHarvard
> University
> >   > P: 646-306-0848
> >   > E: jonahpe...@g.harvard.edu
> >   >
> >   >___
> >   Freesurfer mailing list
> >  

Re: [Freesurfer] Generating Surfaces Meshes

2020-04-23 Thread Bruce Fischl

HI Jonah

it depends how you compute volume. mris_volume for example will compute the 
volume of the interior without any partial volume correction.


And yes, I would expect you want to smooth the surface a bit. You might try 
the Taubin smoothing built into freeview as it won't shrink the surface, 
but you can also try mris_smooth


cheers
Bruce


On Thu, 23 Apr 2020, Peter, Jonah wrote:


Hi Bruce,
I tried mri_tessellate which worked well in that the surface seems to follow 
the aseg projections
exactly. Does the volume of this mesh account for partial volume effects? Also, 
is there a need to run
mri_pretess or some sort of smoothing procedure?

For reference, what I am trying to do is import these surface meshes into a 
Geant4 simulation for proton
therapy, and want to make sure I'm using as realistic geometry as possible. 
Ideally I'd be able to
generate a mesh for the whole brain as well as individual segmentations.

Thanks again for your help,
Jonah

On Thu, Apr 23, 2020 at 5:50 PM Bruce Fischl  wrote:
  no, they are definitely not negligible. It depends on structure geometry,
  but I bet for something like the hippocampus a large fraction of voxels in
  it are partial volumed.

  You can use mri_mc or mri_tessellate to generate a mesh. It will be closed
  but may not have a simple topology

  On Thu, 23 Apr 2020, Peter, Jonah
  wrote:

  > Hi all,
  > Thanks for the response. I'm familiar with partial volume effects 
within the context of
  PET imaging, but
  > wouldn't you expect these effects to be negligible in MRI for 
structures on the order of
  mm?
  >
  > With respect to the mesh type, I'd like to get closed meshes for each
  segmentation/parcellation.
  >
  > Is there a way to do this in freesurfer?
  >
  > On Thu, Apr 23, 2020 at 10:44 AM Bruce Fischl 
 wrote:
  >       Hi Jonah
  >
  >       when we compute volumes we typically use a partial-volume model, 
which we
  >       have found improves accuracy and repeatability. That may be the 
source of
  >       your discrepancy
  >
  >       cheers
  >       Bruce
  >       On Wed, 22 Apr 2020, Peter, Jonah wrote:
  >
  >       > Hello,
  >       > I'm trying to generate surface meshes for different brain 
regions that can
  >       > be imported into a software like MeshLab or Blender (i.e. .STL, 
.PLY, .OBJ,
  >       > etc.). I ran recon-all on my T1 images, and the 
parcellation/segmentation
  >       > looks fine. However, I noticed that when I imported this data 
into 3DSlicer,
  >       > the volumes of these regions did not match the volumes in the 
aseg.stats
  >       > file. In some cases, the differences were quite substantial. I 
tried
  >       > removing all smoothing filters in 3DSlicer but the outcome was 
the same.
  >       >
  >       > Do you know what could be going wrong here? Alternatively, is 
there an
  >       > easier way to generate surface meshes from the aparc or aseg 
atlases?
  >       >
  >       > I'm using the ICBM 2009c Nonlinear Asymmetric
  >       > template (http://nist.mni.mcgill.ca/?p=904) as a generic brain 
volume
  >       > (though alternative suggestions are welcome).
  >       >
  >       > Thanks!
  >       > Jonah
  >       >
  >       > --
  >       > Jonah PeterGraduate Student in The Biophysics ProgramHarvard 
University
  >       > P: 646-306-0848
  >       > E: jonahpe...@g.harvard.edu
  >       >
  >       >___
  >       Freesurfer mailing list
  >       Freesurfer@nmr.mgh.harvard.edu
  >       https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
  >
  >
  >
  > --
  > Jonah PeterGraduate Student in The Biophysics ProgramHarvard University
  > P: 646-306-0848
  > E: jonahpe...@g.harvard.edu
  >
  >___
  Freesurfer mailing list
  Freesurfer@nmr.mgh.harvard.edu
  https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer



--
Jonah PeterGraduate Student in The Biophysics ProgramHarvard University
P: 646-306-0848
E: jonahpe...@g.harvard.edu

___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Generating Surfaces Meshes

2020-04-23 Thread Peter, Jonah
Hi Bruce,

I tried mri_tessellate which worked well in that the surface seems to
follow the aseg projections exactly. Does the volume of this mesh account
for partial volume effects? Also, is there a need to run mri_pretess or
some sort of smoothing procedure?

For reference, what I am trying to do is import these surface meshes into a
Geant4 simulation for proton therapy, and want to make sure I'm using as
realistic geometry as possible. Ideally I'd be able to generate a mesh for
the whole brain as well as individual segmentations.

Thanks again for your help,
Jonah

On Thu, Apr 23, 2020 at 5:50 PM Bruce Fischl 
wrote:

> no, they are definitely not negligible. It depends on structure geometry,
> but I bet for something like the hippocampus a large fraction of voxels in
> it are partial volumed.
>
> You can use mri_mc or mri_tessellate to generate a mesh. It will be closed
> but may not have a simple topology
>
> On Thu, 23 Apr 2020, Peter, Jonah
> wrote:
>
> > Hi all,
> > Thanks for the response. I'm familiar with partial volume effects within
> the context of PET imaging, but
> > wouldn't you expect these effects to be negligible in MRI for structures
> on the order of mm?
> >
> > With respect to the mesh type, I'd like to get closed meshes for each
> segmentation/parcellation.
> >
> > Is there a way to do this in freesurfer?
> >
> > On Thu, Apr 23, 2020 at 10:44 AM Bruce Fischl <
> fis...@nmr.mgh.harvard.edu> wrote:
> >   Hi Jonah
> >
> >   when we compute volumes we typically use a partial-volume model,
> which we
> >   have found improves accuracy and repeatability. That may be the
> source of
> >   your discrepancy
> >
> >   cheers
> >   Bruce
> >   On Wed, 22 Apr 2020, Peter, Jonah wrote:
> >
> >   > Hello,
> >   > I'm trying to generate surface meshes for different brain
> regions that can
> >   > be imported into a software like MeshLab or Blender (i.e. .STL,
> .PLY, .OBJ,
> >   > etc.). I ran recon-all on my T1 images, and the
> parcellation/segmentation
> >   > looks fine. However, I noticed that when I imported this data
> into 3DSlicer,
> >   > the volumes of these regions did not match the volumes in the
> aseg.stats
> >   > file. In some cases, the differences were quite substantial. I
> tried
> >   > removing all smoothing filters in 3DSlicer but the outcome was
> the same.
> >   >
> >   > Do you know what could be going wrong here? Alternatively, is
> there an
> >   > easier way to generate surface meshes from the aparc or aseg
> atlases?
> >   >
> >   > I'm using the ICBM 2009c Nonlinear Asymmetric
> >   > template (http://nist.mni.mcgill.ca/?p=904) as a generic brain
> volume
> >   > (though alternative suggestions are welcome).
> >   >
> >   > Thanks!
> >   > Jonah
> >   >
> >   > --
> >   > Jonah PeterGraduate Student in The Biophysics ProgramHarvard
> University
> >   > P: 646-306-0848
> >   > E: jonahpe...@g.harvard.edu
> >   >
> >   >___
> >   Freesurfer mailing list
> >   Freesurfer@nmr.mgh.harvard.edu
> >   https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
> >
> >
> >
> > --
> > Jonah PeterGraduate Student in The Biophysics ProgramHarvard University
> > P: 646-306-0848
> > E: jonahpe...@g.harvard.edu
> >
> >___
> Freesurfer mailing list
> Freesurfer@nmr.mgh.harvard.edu
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer



-- 
Jonah Peter
Graduate Student in The Biophysics Program
Harvard University
P: 646-306-0848
E: jonahpe...@g.harvard.edu
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Trac-All NaN

2020-04-23 Thread Yendiki, Anastasia
Those values are at the endpoints of the tracts. As the median tract may be a 
bit longer or shorter in different subjects, the endpoints don't always have 
corresponding points in all subjects

From: freesurfer-boun...@nmr.mgh.harvard.edu 
 on behalf of Hua, Jessica 

Sent: Thursday, April 23, 2020 4:01 PM
To: freesurfer@nmr.mgh.harvard.edu 
Subject: [Freesurfer] Trac-All NaN


External Email - Use Caution

Hi FreeSurfer,

I ran the trac-all -stat command on some of my participants, and I noticed that 
some of the values that were outputted contained NaN.  Why are the values 
coming out as NaN?

fmajor_PP.avg33_mni_bbr.AD_Avg.txt
S11018a_LGI S11019a_LGI S11021a_LGI
NaN NaN 0.00109668
0.00116704 NaN 0.00110631
0.00118262 NaN 0.00113231
0.00119589 NaN 0.00116401
0.00121558 NaN 0.00117549
0.00123733 NaN 0.00119309
0.00126087 NaN 0.00123177
0.00127355 0.00116328 0.00127236
0.00126695 0.00115413 0.00129993
0.00125837 0.00117334 0.00131861
0.00125611 0.00117423 0.00134501
0.00130347 0.00117161 0.00135121
0.00133526 0.00117097 0.00136288
0.00135801 0.00116546 0.00136839
0.00138131 0.0011961 0.00141117
0.00137605 0.00126803 0.00143167
0.00139927 0.00132198 0.00144947
0.00140814 0.00135481 0.00145095
0.00141403 0.00136342 0.00144231
0.00143846 0.00136409 0.0014307
0.00144842 0.00134806 0.00141466
0.00144669 0.00138324 0.00139904
0.00144974 0.00143263 0.00139749
0.00146505 0.00145596 0.00143352
0.00149473 0.0014523 0.00144366
0.00150771 0.0014622 0.00144891
0.00151567 0.00148269 0.00147786
0.0015513 0.00151399 0.00153047
0.00158431 0.00155476 0.00160898
0.00163524 0.00162621 0.00166298
0.00166918 0.0016651 0.0016538
0.00165915 0.00165803 0.00169534
0.00171513 0.00164646 0.00176355
0.00178509 0.00167836 0.00179073
0.00186456 0.00175883 0.00181997
0.00187805 0.00183493 0.00178465
0.00189962 0.00187421 0.00175515
0.00192235 0.00189781 0.00171387
0.0019091 0.00184765 0.00160073
0.00191175 0.00181558 0.00157862
0.00191679 0.00182829 0.00165907
0.00185513 0.00185947 0.0017003
0.00181572 0.00189271 0.00172307
0.00181154 0.0018763 0.00159418
0.0018311 0.0018657 0.00159179
0.00172958 0.00189407 0.00164795
0.00165341 0.00191997 0.00167435
0.00156794 0.00190814 0.00168963
0.00146072 0.001859 0.00172164
0.00138372 0.00178192 0.00175954
0.00136893 0.00170486 0.0018261
0.0013654 0.00164533 0.0018264
0.00135974 0.00155251 0.00176598
0.00137226 0.00149038 0.00166574
0.00133654 0.00146834 0.00152383
0.00134757 0.00148128 0.00138086
0.00136271 0.00147022 0.00132929
0.00136545 0.00144934 0.00127674
0.00137979 0.00145088 0.00125313
0.00137398 0.00151918 0.00125802
0.00137699 0.00151537 0.00126461
0.00136867 0.00146195 0.00126159
0.00136882 0.00140568 0.0012639
0.00134777 0.00138923 0.00126469
0.00127934 0.00138564 0.00127229
0.00122813 0.00138057 0.00128295
0.00118596 0.00138419 0.00129555
0.00117204 0.0013933 0.00131012
0.00114282 0.0013934 0.00129255
0.00114104 0.00141831 0.0012982
0.00116965 0.00141932 0.00128999
0.00118427 0.00139441 0.00128321
0.00117267 0.0013619 0.00127428
0.00117105 0.00133817 0.00124349
0.00114046 0.00131501 0.00121045
NaN 0.0012865 0.00117847
NaN 0.00126657 0.00114993
NaN 0.00123952 0.00113779
NaN NaN 0.00112863

Jessica

---

Jessica Hua, M.A.
Cognitive and Emotional Control Lab
Doctoral Candidate Clinical Psychology
University of Missouri
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Generating Surfaces Meshes

2020-04-23 Thread Bruce Fischl
no, they are definitely not negligible. It depends on structure geometry, 
but I bet for something like the hippocampus a large fraction of voxels in 
it are partial volumed.


You can use mri_mc or mri_tessellate to generate a mesh. It will be closed 
but may not have a simple topology


On Thu, 23 Apr 2020, Peter, Jonah 
wrote:



Hi all,
Thanks for the response. I'm familiar with partial volume effects within the 
context of PET imaging, but
wouldn't you expect these effects to be negligible in MRI for structures on the 
order of mm?

With respect to the mesh type, I'd like to get closed meshes for each 
segmentation/parcellation.

Is there a way to do this in freesurfer?

On Thu, Apr 23, 2020 at 10:44 AM Bruce Fischl  
wrote:
  Hi Jonah

  when we compute volumes we typically use a partial-volume model, which we
  have found improves accuracy and repeatability. That may be the source of
  your discrepancy

  cheers
  Bruce
  On Wed, 22 Apr 2020, Peter, Jonah wrote:

  > Hello,
  > I'm trying to generate surface meshes for different brain regions that 
can
  > be imported into a software like MeshLab or Blender (i.e. .STL, .PLY, 
.OBJ,
  > etc.). I ran recon-all on my T1 images, and the 
parcellation/segmentation
  > looks fine. However, I noticed that when I imported this data into 
3DSlicer,
  > the volumes of these regions did not match the volumes in the aseg.stats
  > file. In some cases, the differences were quite substantial. I tried
  > removing all smoothing filters in 3DSlicer but the outcome was the same.
  >
  > Do you know what could be going wrong here? Alternatively, is there an
  > easier way to generate surface meshes from the aparc or aseg atlases?
  >
  > I'm using the ICBM 2009c Nonlinear Asymmetric
  > template (http://nist.mni.mcgill.ca/?p=904) as a generic brain volume
  > (though alternative suggestions are welcome).
  >
  > Thanks!
  > Jonah
  >
  > --
  > Jonah PeterGraduate Student in The Biophysics ProgramHarvard University
  > P: 646-306-0848
  > E: jonahpe...@g.harvard.edu
  >
  >___
  Freesurfer mailing list
  Freesurfer@nmr.mgh.harvard.edu
  https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer



--
Jonah PeterGraduate Student in The Biophysics ProgramHarvard University
P: 646-306-0848
E: jonahpe...@g.harvard.edu

___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Generating Surfaces Meshes

2020-04-23 Thread Peter, Jonah
Hi all,

Thanks for the response. I'm familiar with partial volume effects within
the context of PET imaging, but wouldn't you expect these effects to be
negligible in MRI for structures on the order of mm?

With respect to the mesh type, I'd like to get closed meshes for each
segmentation/parcellation.

Is there a way to do this in freesurfer?

On Thu, Apr 23, 2020 at 10:44 AM Bruce Fischl 
wrote:

> Hi Jonah
>
> when we compute volumes we typically use a partial-volume model, which we
> have found improves accuracy and repeatability. That may be the source of
> your discrepancy
>
> cheers
> Bruce
> On Wed, 22 Apr 2020, Peter, Jonah wrote:
>
> > Hello,
> > I'm trying to generate surface meshes for different brain regions that
> can
> > be imported into a software like MeshLab or Blender (i.e. .STL, .PLY,
> .OBJ,
> > etc.). I ran recon-all on my T1 images, and the parcellation/segmentation
> > looks fine. However, I noticed that when I imported this data into
> 3DSlicer,
> > the volumes of these regions did not match the volumes in the aseg.stats
> > file. In some cases, the differences were quite substantial. I tried
> > removing all smoothing filters in 3DSlicer but the outcome was the same.
> >
> > Do you know what could be going wrong here? Alternatively, is there an
> > easier way to generate surface meshes from the aparc or aseg atlases?
> >
> > I'm using the ICBM 2009c Nonlinear Asymmetric
> > template (http://nist.mni.mcgill.ca/?p=904) as a generic brain volume
> > (though alternative suggestions are welcome).
> >
> > Thanks!
> > Jonah
> >
> > --
> > Jonah PeterGraduate Student in The Biophysics ProgramHarvard University
> > P: 646-306-0848
> > E: jonahpe...@g.harvard.edu
> >
> >___
> Freesurfer mailing list
> Freesurfer@nmr.mgh.harvard.edu
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer



-- 
Jonah Peter
Graduate Student in The Biophysics Program
Harvard University
P: 646-306-0848
E: jonahpe...@g.harvard.edu
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

[Freesurfer] Trac-All NaN

2020-04-23 Thread Hua, Jessica
External Email - Use Caution

Hi FreeSurfer,

I ran the trac-all -stat command on some of my participants, and I noticed that 
some of the values that were outputted contained NaN.  Why are the values 
coming out as NaN?

fmajor_PP.avg33_mni_bbr.AD_Avg.txt
S11018a_LGI S11019a_LGI S11021a_LGI
NaN NaN 0.00109668
0.00116704 NaN 0.00110631
0.00118262 NaN 0.00113231
0.00119589 NaN 0.00116401
0.00121558 NaN 0.00117549
0.00123733 NaN 0.00119309
0.00126087 NaN 0.00123177
0.00127355 0.00116328 0.00127236
0.00126695 0.00115413 0.00129993
0.00125837 0.00117334 0.00131861
0.00125611 0.00117423 0.00134501
0.00130347 0.00117161 0.00135121
0.00133526 0.00117097 0.00136288
0.00135801 0.00116546 0.00136839
0.00138131 0.0011961 0.00141117
0.00137605 0.00126803 0.00143167
0.00139927 0.00132198 0.00144947
0.00140814 0.00135481 0.00145095
0.00141403 0.00136342 0.00144231
0.00143846 0.00136409 0.0014307
0.00144842 0.00134806 0.00141466
0.00144669 0.00138324 0.00139904
0.00144974 0.00143263 0.00139749
0.00146505 0.00145596 0.00143352
0.00149473 0.0014523 0.00144366
0.00150771 0.0014622 0.00144891
0.00151567 0.00148269 0.00147786
0.0015513 0.00151399 0.00153047
0.00158431 0.00155476 0.00160898
0.00163524 0.00162621 0.00166298
0.00166918 0.0016651 0.0016538
0.00165915 0.00165803 0.00169534
0.00171513 0.00164646 0.00176355
0.00178509 0.00167836 0.00179073
0.00186456 0.00175883 0.00181997
0.00187805 0.00183493 0.00178465
0.00189962 0.00187421 0.00175515
0.00192235 0.00189781 0.00171387
0.0019091 0.00184765 0.00160073
0.00191175 0.00181558 0.00157862
0.00191679 0.00182829 0.00165907
0.00185513 0.00185947 0.0017003
0.00181572 0.00189271 0.00172307
0.00181154 0.0018763 0.00159418
0.0018311 0.0018657 0.00159179
0.00172958 0.00189407 0.00164795
0.00165341 0.00191997 0.00167435
0.00156794 0.00190814 0.00168963
0.00146072 0.001859 0.00172164
0.00138372 0.00178192 0.00175954
0.00136893 0.00170486 0.0018261
0.0013654 0.00164533 0.0018264
0.00135974 0.00155251 0.00176598
0.00137226 0.00149038 0.00166574
0.00133654 0.00146834 0.00152383
0.00134757 0.00148128 0.00138086
0.00136271 0.00147022 0.00132929
0.00136545 0.00144934 0.00127674
0.00137979 0.00145088 0.00125313
0.00137398 0.00151918 0.00125802
0.00137699 0.00151537 0.00126461
0.00136867 0.00146195 0.00126159
0.00136882 0.00140568 0.0012639
0.00134777 0.00138923 0.00126469
0.00127934 0.00138564 0.00127229
0.00122813 0.00138057 0.00128295
0.00118596 0.00138419 0.00129555
0.00117204 0.0013933 0.00131012
0.00114282 0.0013934 0.00129255
0.00114104 0.00141831 0.0012982
0.00116965 0.00141932 0.00128999
0.00118427 0.00139441 0.00128321
0.00117267 0.0013619 0.00127428
0.00117105 0.00133817 0.00124349
0.00114046 0.00131501 0.00121045
NaN 0.0012865 0.00117847
NaN 0.00126657 0.00114993
NaN 0.00123952 0.00113779
NaN NaN 0.00112863

Jessica

---

Jessica Hua, M.A.
Cognitive and Emotional Control Lab
Doctoral Candidate Clinical Psychology
University of Missouri
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

[Freesurfer] Overlapping Treatments and fsgd files

2020-04-23 Thread Matthew Peverill
External Email - Use Caution

Hello all,
I hope everyone is staying safe and sane out there. I'm running an analysis
looking at brain structure differences associated with two separate
environmental exposures in children (both dichotomous variables). I am
controlling for sex and age, and I'm not interested in interaction effects.
My go-to strategy does not match the documentation, but I'm not sure the
documented solution using fsgd files will meet my needs. I was hoping I
could check with the list about best practices.

Because some participants have both exposures, my intuition was to use
dummy coded variables so that the design matrix looks like this:

+1.0 +3.11124 -0.48322 -0.51007 -0.53020
+1.0 -0.20820 +0.51678 -0.51007 -0.53020
+1.0 -2.06654 -0.48322 -0.51007 -0.53020
...

Where the columns are (mean, mean centered age, mean centered sex, mean
centered exposure 1, mean centered exposure 2). A contrast for exposure 1 -
exposure 2 would then look like this:

[0, 0, 0, 1, -1]

However, it's clear from the documentation that, given 3, 2 level factors,
the recommended approach is to specify 8 classes (one for every combination
of factors) and the covariate in an fsgd file. I can remove the interaction
terms from the resulting matrix, but even so it looks very different than
what I had above:

+1.0 +0.0 +0.0 +0.0 +0.0 +0.0 +0.0 +0.0
+3.11124
+0.0 +1.0 +0.0 +0.0 +0.0 +0.0 +0.0 +0.0
+0.0
+1.0 +0.0 +0.0 +0.0 +0.0 +0.0 +0.0 +0.0
-2.06654
...

With a contrast with all classes with exposure 1 set to '1', and all
classes with exposure 2 set to '-1' - with the order of the classes in the
fsgd file it comes out as [-1 -1 1 1 1 1 -1 -1 0].

I'm not positive that this is the right way to model differences associated
with each exposure given unequal #s of participants with neither/both/just
one exposure, but I certainly don't have the expertise to be certain. Could
someone give me some guidance on the best approach here? Thank you,

-Matt

-- 
Matthew Peverill
857-277-9083
mrpever...@gmail.com (preferred)
pronouns: he/his
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] ROIs to surface overlays / Arithmetic on surface overlays

2020-04-23 Thread Bruce Fischl

Hi Quentin

if you import it as a surface label you should be able to use morphological 
operations to smooth it (open, close, dilate, erode)


cheers
Bruce


On Thu, 23 Apr 2020, Funk, Quentin wrote:



External Email - Use Caution

Freesurfer experts,

I have a volumetric ROI (integer valued) in MNI space. I'd really like to
display them on the fsaverage brain as a surface overlay so that it's clear
what regions I'm looking at. 

Using something like this, I get pretty good results:

mri_vol2surf --mov ROI_integers.nii  --regheader fsaverage  --hemi lh --out
left_overlay.mgh --projfrac-max 0.15 .17 .01

but the edges are kind of a mess, see: https://imgur.com/a/53RVGCM

Is there any way to smooth these edges while maintaining the "lookup table'
nature of the surface overlay? Any kind of interpolation ruins that, so it's
a bit hard (you can't see in that image, but there are multiple regions
shown).

Alternatively, is there any way I can do arithmetic with surfaces? If there
were a tool like fslmaths for surface overlays, solving this problem would
be relatively straightforward.

Thanks for any help you can provide!

-quentin funk

Houston Methodist. Leading Medicine.

Houston Methodist is ranked by U.S. News & World Report as the No. 1
hospital in Texas and among the top 20 hospitals nationwide. Houston
Methodist is the only nationally ranked Honor Roll hospital in the state and
is designated as a Magnet hospital for excellence in nursing.


houstonmethodist.org | twitter.com/MethodistHosp |
facebook.com/HoustonMethodist

***CONFIDENTIALITY NOTICE*** This e-mail is the property of Houston
Methodist and/or its relevant affiliates and may contain restricted and
privileged material for the sole use of the intended recipient(s). Any
review, use, distribution or disclosure by others is strictly prohibited. If
you are not the intended recipient (or authorized to receive for the
recipient), please contact the sender and delete all copies of the message.
Thank you.


___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Cortical thickness measure for external analysis.

2020-04-23 Thread Bruce Fischl
you should be fine with the subject metrics we generate. Typically 
thickness doesn't need much if any eTIV correction
On Thu, 23 Apr 2020, 
Miguel Ángel Rivas Fernández wrote:




External Email - Use Caution

Dear Freesurfer experts,

We are interested in running external analysis with thickness measurements
of two brain regions. Can we use safely the metrics exported or by contrary
a previous transformation is required before export the stats of each
subject?

Thanks for your time.

Best regards,

--
Miguel Ángel Rivas Fernández

___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

[Freesurfer] ROIs to surface overlays / Arithmetic on surface overlays

2020-04-23 Thread Funk, Quentin
External Email - Use Caution

Freesurfer experts,

I have a volumetric ROI (integer valued) in MNI space. I'd really like to 
display them on the fsaverage brain as a surface overlay so that it's clear 
what regions I'm looking at.

Using something like this, I get pretty good results:

mri_vol2surf --mov ROI_integers.nii  --regheader fsaverage  --hemi lh --out 
left_overlay.mgh --projfrac-max 0.15 .17 .01

but the edges are kind of a mess, see: https://imgur.com/a/53RVGCM

Is there any way to smooth these edges while maintaining the "lookup table' 
nature of the surface overlay? Any kind of interpolation ruins that, so it's a 
bit hard (you can't see in that image, but there are multiple regions shown).

Alternatively, is there any way I can do arithmetic with surfaces? If there 
were a tool like fslmaths for surface overlays, solving this problem would be 
relatively straightforward.

Thanks for any help you can provide!

-quentin funk

Houston Methodist. Leading Medicine. Houston Methodist is ranked by U.S. News & 
World Report as the No. 1 hospital in Texas and among the top 20 hospitals 
nationwide. Houston Methodist is the only nationally ranked Honor Roll hospital 
in the state and is designated as a Magnet hospital for excellence in nursing.
houstonmethodist.org | twitter.com/MethodistHosp | 
facebook.com/HoustonMethodist ***CONFIDENTIALITY NOTICE*** This e-mail is the 
property of Houston Methodist and/or its relevant affiliates and may contain 
restricted and privileged material for the sole use of the intended 
recipient(s). Any review, use, distribution or disclosure by others is strictly 
prohibited. If you are not the intended recipient (or authorized to receive for 
the recipient), please contact the sender and delete all copies of the message. 
Thank you.
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Generating Surfaces Meshes

2020-04-23 Thread Bruce Fischl

Hi Jonah

when we compute volumes we typically use a partial-volume model, which we 
have found improves accuracy and repeatability. That may be the source of 
your discrepancy


cheers
Bruce
On Wed, 22 Apr 2020, Peter, Jonah wrote:


Hello,
I'm trying to generate surface meshes for different brain regions that can
be imported into a software like MeshLab or Blender (i.e. .STL, .PLY, .OBJ,
etc.). I ran recon-all on my T1 images, and the parcellation/segmentation
looks fine. However, I noticed that when I imported this data into 3DSlicer,
the volumes of these regions did not match the volumes in the aseg.stats
file. In some cases, the differences were quite substantial. I tried
removing all smoothing filters in 3DSlicer but the outcome was the same.

Do you know what could be going wrong here? Alternatively, is there an
easier way to generate surface meshes from the aparc or aseg atlases?

I'm using the ICBM 2009c Nonlinear Asymmetric
template (http://nist.mni.mcgill.ca/?p=904) as a generic brain volume
(though alternative suggestions are welcome).

Thanks!
Jonah

--
Jonah PeterGraduate Student in The Biophysics ProgramHarvard University
P: 646-306-0848
E: jonahpe...@g.harvard.edu

___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

[Freesurfer] Cortical thickness measure for external analysis.

2020-04-23 Thread Miguel Ángel Rivas Fernández
External Email - Use Caution

Dear Freesurfer experts,

We are interested in running external analysis with thickness measurements
of two brain regions. Can we use safely the metrics exported or by contrary
a previous transformation is required before export the stats of each
subject?

Thanks for your time.

Best regards,

-- 
*Miguel Ángel Rivas Fernández*
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Generating Surfaces Meshes

2020-04-23 Thread Tim Schäfer
External Email - Use Caution

Could you clarify what kind of meshes you are working with? Are the meshes you 
are working with plane-like (parts of the pial surface), or are they closed 
(e.g., generating from running marching cubes on a set of cortex voxels)?

Also what is your intention, i.e., what do you want to do with the meshes?

The exact volume inside the mesh will always depend on the parameters of the 
mesh generation algorithm.

Best,

Tim


> On April 23, 2020 at 1:14 AM "Peter, Jonah"  wrote:
> 
> 
> Hello,
> 
> I'm trying to generate surface meshes for different brain regions that can
> be imported into a software like MeshLab or Blender (i.e. .STL, .PLY, .OBJ,
> etc.). I ran recon-all on my T1 images, and the parcellation/segmentation
> looks fine. However, I noticed that when I imported this data into
> 3DSlicer, the volumes of these regions did not match the volumes in the
> aseg.stats file. In some cases, the differences were quite substantial. I
> tried removing all smoothing filters in 3DSlicer but the outcome was the
> same.
> 
> Do you know what could be going wrong here? Alternatively, is there an
> easier way to generate surface meshes from the aparc or aseg atlases?
> 
> I'm using the ICBM 2009c Nonlinear Asymmetric template (
> http://nist.mni.mcgill.ca/?p=904) as a generic brain volume (though
> alternative suggestions are welcome).
> 
> Thanks!
> Jonah
> 
> -- 
> Jonah Peter
> Graduate Student in The Biophysics Program
> Harvard University
> P: 646-306-0848
> E: jonahpe...@g.harvard.edu
> ___
> 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