help > Problem displaying surface-level analyses
Showing 1-25 of 28 posts
Display:
Results per page:

1   2   Next >
Jan 22, 2020  01:01 AM | Amy Bouchard
Problem displaying surface-level analyses
Hi Alfonso,

There is a problem displaying results for ROI-to-ROI surface analyses (see attachment). Some of the regions are outside the brain.

Could you please advise on how to fix this?

Also, are 10 diffusion steps sufficient for smoothing?

Thank you,
Best Regards,
Amy
Jan 27, 2020  11:01 AM | Alfonso Nieto-Castanon - Boston University
RE: Problem displaying surface-level analyses
Hi Amy,

Thanks for reporting this, it looks like the coordinates of your ROIs are being misinterpreted by these displays. Could you please let me know a bit more information about the specifc ROIs that you are using here? are they surface-based ROIs defined for example using a freesurfer .annot file, are they defined in MNI-space ROIs but simply part of an otherwise surface-level analysis, what functional data are they associated with -in the "compute average timeseries from .. dataset." field-, etc.

And regarding diffusion steps, 10 is a minimal value (somewhat similar to ~4mm in 3d volumes) I typically find 40 steps (somewhat similar to ~8mm in 3d volumes) a little bit better (for more details see Hagler Jr, D. J., Saygin, A. P., & Sereno, M. I. (2006). Smoothing and cluster thresholding for cortical surface-based group analysis of fMRI data. Neuroimage, 33(4), 1093-1103)

Thanks
Alfonso
Originally posted by Amy Bouchard:
Hi Alfonso,

There is a problem displaying results for ROI-to-ROI surface analyses (see attachment). Some of the regions are outside the brain.

Could you please advise on how to fix this?

Also, are 10 diffusion steps sufficient for smoothing?

Thank you,
Best Regards,
Amy
Jan 27, 2020  03:01 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi Alfonso,

The ROIs are surface-based subject-specific ROIs from Freesurfer's DKTatlas+aseg.mgz files. They are associated with the apart.DKTatlas+aseg text file for the labelling.
The following advanced options are selected: atlas file, subject-specific ROI; mask with grey matter.
They are associated with the functional data "compute average timeseries from secondary dataset #1 unsmoothed volumes".
I conducted preprocessing with CONN's default surface-based pipeline.

Thanks,
Amy
Feb 5, 2020  11:02 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi again Alfonso,

I re-conducted the surface-based analyses using the default surface preprocessing pipeline, as well as smoothing with 40 diffusion steps.

There are problems with displays in the QA plots (see attached).

To note, I removed the last preprocessing step since I entered freesurfer brainmask volumes with segmented grey matter, etc.

Thanks for your help,
Amy
Attachment: Problem.pdf
Feb 6, 2020  12:02 AM | Alfonso Nieto-Castanon - Boston University
RE: Problem displaying surface-level analyses
Hi Amy,

One issue there is that Freesurfer aparc*+aseg.mgz files are not really surface-space files like the associated lh.aparc*.annot files (i.e. defined in fsaverage space), they are instead projected back to subject-space (i.e. in the same space as your structural data), so if you want to import those in CONN as ROIs you need to associated them with your "subject-space" functional data, rather than your "surface-space" data (i.e. select the option that reads "compute average timeseries from secondary dataset #5 (subject-space data)"

Hope this helps
Alfonso

Originally posted by Amy Bouchard:
Hi Alfonso,

The ROIs are surface-based subject-specific ROIs from Freesurfer's DKTatlas+aseg.mgz files. They are associated with the apart.DKTatlas+aseg text file for the labelling.
The following advanced options are selected: atlas file, subject-specific ROI; mask with grey matter.
They are associated with the functional data "compute average timeseries from secondary dataset #1 unsmoothed volumes".
I conducted preprocessing with CONN's default surface-based pipeline.

Thanks,
Amy
Feb 6, 2020  01:02 AM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi Alfonso,

great, thanks so much for your help! I will try that!

Best Regards,
Amy
Feb 12, 2020  05:02 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi again Alfonso,
I re-conducted the surface-based analyses using CONN v. 19.b, however, when I select the 3D display in the 2nd level analyses, the ROIs are still outside the brain. I associated the ROI files with subject-space functional data as you suggested. 
Could you please advise on how to fix this? I am open to using another atlas file or another procedure.
Thanks,
Amy
Feb 14, 2020  01:02 PM | Alfonso Nieto-Castanon - Boston University
RE: Problem displaying surface-level analyses
Hi Amy,

Sorry for the late reply, I believe the remaining issue is simply that subject-specific ROIs (like those we are using here, defining by FreeSurfer and located at a different location for each subject) do not have any associated unique and well-defined MNI-space coordinates. The second-level results display functions will attempt to place these ROIs at the world-coordinates specified for the first subject, but those are going to look out-of-place if the reference space of the first subject (in this case that is the space of the T1w image that was processed by FreeSurfer) is off the standard MNI-space reference. This means that your ROIs are being properly defined now, but CONN does not have a way to figure out where to locate them in MNI-space for plotting purposes. 

One way to work around this issue, which only applies to FreeSurfer-generated ROIs (not to other forms of subject-specific ROIs), is to enter in the Setup.ROIs tab instead of the aparc*+aseg.mgz files (one subject-specifc RO defining your FreeSurfer ROIs projected back into subject-space) directly the associated lh.aparc*+aseg.annot files (a single subject-independent file defining the same FreeSurfer ROIs but in fsaverage space), and then selecting the option that reads "compute average timeseries from unsmoothed volumes" (assuming that you have used CONN's surface-based pipeline, after the "functional_surface_resample" step those functional volumes would also be defined in fsaverage space). When doing this, the ROI functional data is still going to be extracted from the correct cortical locations separately for each individual subject, but now CONN is going to automatically associate with each individual ROI a set of reference MNI-space coordinates (which are only used for display purposes) defined by the position of the centroid of this ROI in the MNI-space FreeSurfer reference lh/rh.pial surface (see "conn_surf_coords.m" for details). This allows conn second-level plotting functions to use some "reasonable" MNI-space coordinates when displaying each ROI (of course, these reference coordinates are not perfectly accurate simply because in reality the coordinates of each ROI may actually be in different locations for different subjects, and also the fsaverage reference surfaces are just an approximation to where the subject-specific surfaces will be for each subject, but at least they should be reasonably indicative of the general location in MNI-space of each ROI)

Let me know if that makes sense and/or if you run into issues. 

Best
Alfonso

Originally posted by Amy Bouchard:
Hi again Alfonso,
I re-conducted the surface-based analyses using CONN v. 19.b, however, when I select the 3D display in the 2nd level analyses, the ROIs are still outside the brain. I associated the ROI files with subject-space functional data as you suggested. 
Could you please advise on how to fix this? I am open to using another atlas file or another procedure.
Thanks,
Amy
Feb 15, 2020  11:02 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi Alfonso,

unfortunately there is an error when loading the aparc.annot files:

ERROR DESCRIPTION:

Error using horzcat
Dimensions of arrays being concatenated are not consistent.
Error in conn_annot2nii (line 51)
data=[log.data{ifile(1)}(:) log.data{ifile(2)}(:)];
Error in conn_getinfo (line 17)
filename=conn_annot2nii(filename);
Error in conn_file (line 11)
[nV,str,icon,filename]=conn_getinfo(filename,doconvert);
Error in conn (line 2552)
fileinfo=conn_file(deblank(filename(1,:)));
Error in conn_filesearchtool (line 222)
if length(h.callback)>1, feval(h.callback{1},h.callback{2:end},names); else, feval(h.callback{1},names); end
CONN19.b
SPM12 + DEM FieldMap MEEGtools
Matlab v.2019a
project: CONN18.b
storage: 738.6Gb available
spm @ C:\spm12
conn @ C:\conn

Could you please help?


Thanks,
Amy
Feb 16, 2020  12:02 AM | Alfonso Nieto-Castanon - Boston University
RE: Problem displaying surface-level analyses
Hi Amy,

I believe this may indicate that you are attempting to load the subject-specific lh.aparc*.annot files (resampled to each subject cortical tessellation, and typically located in each subject label folder). If that is the case, simply load instead a single reference lh.aparc*.annot file (defined in fsaverage space, and typically located in freesurfer fsaverage folder)

Best
Alfonso

Originally posted by Amy Bouchard:
Hi Alfonso,

unfortunately there is an error when loading the aparc.annot files:

ERROR DESCRIPTION:

Error using horzcat
Dimensions of arrays being concatenated are not consistent.
Error in conn_annot2nii (line 51)
data=[log.data{ifile(1)}(:) log.data{ifile(2)}(:)];
Error in conn_getinfo (line 17)
filename=conn_annot2nii(filename);
Error in conn_file (line 11)
[nV,str,icon,filename]=conn_getinfo(filename,doconvert);
Error in conn (line 2552)
fileinfo=conn_file(deblank(filename(1,:)));
Error in conn_filesearchtool (line 222)
if length(h.callback)>1, feval(h.callback{1},h.callback{2:end},names); else, feval(h.callback{1},names); end
CONN19.b
SPM12 + DEM FieldMap MEEGtools
Matlab v.2019a
project: CONN18.b
storage: 738.6Gb available
spm @ C:\spm12
conn @ C:\conn

Could you please help?


Thanks,
Amy
Feb 16, 2020  02:02 AM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi Alfonso,

Thank you for your quick reply!

Unfortunately there is still an error : 

ERROR DESCRIPTION:

Output argument "vertices" (and maybe others) not assigned during call to "conn_freesurfer_read_annotation".
Error in conn_annot2nii (line 23)
[temp_vert,temp_label,temp_table]=conn_freesurfer_read_annotation(roifile,0);
Error in conn_getinfo (line 17)
filename=conn_annot2nii(filename);
Error in conn_file (line 11)
[nV,str,icon,filename]=conn_getinfo(filename,doconvert);
Error in conn (line 2552)
fileinfo=conn_file(deblank(filename(1,:)));
Error in conn_filesearchtool (line 222)
if length(h.callback)>1, feval(h.callback{1},h.callback{2:end},names); else, feval(h.callback{1},names); end
CONN19.b
SPM12 + DEM FieldMap MEEGtools
Matlab v.2019a
project: CONN18.b
storage: 738.6Gb available
spm @ C:\spm12
conn @ C:\conn

Could you please help me?

Thanks,
Amy
Feb 16, 2020  01:02 PM | Alfonso Nieto-Castanon - Boston University
RE: Problem displaying surface-level analyses
Hi Amy,
That's strange. This error indicates that freesurfer's read_annotation function seems to have trouble interpreting this annotation file. Could you please send me your .annot file and a brief description of how it was created?
Thanks
Alfonso
Originally posted by Amy Bouchard:
Hi Alfonso,

Thank you for your quick reply!

Unfortunately there is still an error : 

ERROR DESCRIPTION:

Output argument "vertices" (and maybe others) not assigned during call to "conn_freesurfer_read_annotation".
Error in conn_annot2nii (line 23)
[temp_vert,temp_label,temp_table]=conn_freesurfer_read_annotation(roifile,0);
Error in conn_getinfo (line 17)
filename=conn_annot2nii(filename);
Error in conn_file (line 11)
[nV,str,icon,filename]=conn_getinfo(filename,doconvert);
Error in conn (line 2552)
fileinfo=conn_file(deblank(filename(1,:)));
Error in conn_filesearchtool (line 222)
if length(h.callback)>1, feval(h.callback{1},h.callback{2:end},names); else, feval(h.callback{1},names); end
CONN19.b
SPM12 + DEM FieldMap MEEGtools
Matlab v.2019a
project: CONN18.b
storage: 738.6Gb available
spm @ C:\spm12
conn @ C:\conn

Could you please help me?

Thanks,
Amy
Feb 16, 2020  07:02 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi Alfonso,

please find attached the lh.aparc.DKTatlas.annot file. 

I processed the structural images using Recon-all on CBrain's computing platform (Sherif et al 2014, Front Neuroinform).

I masked the DKT ROI files with grey matter, is this a correct procedure?

Thanks for your help,
Amy
Feb 16, 2020  07:02 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi again Alfonso,

I just noticed some strange lines on the ROI masks (see attached).

Could you please advise?

Thanks,
Amy
Feb 16, 2020  07:02 PM | Alfonso Nieto-Castanon - Boston University
RE: Problem displaying surface-level analyses
Hi Amy,
That looks readable/fine, could you please attach the rh.aparc.DKTatlas.annot file as well?
Thanks
Alfonso
Originally posted by Amy Bouchard:
Hi Alfonso,

please find attached the lh.aparc.DKTatlas.annot file. 

I processed the structural images using Recon-all on CBrain's computing platform (Sherif et al 2014, Front Neuroinform).

I masked the DKT ROI files with grey matter, is this a correct procedure?

Thanks for your help,
Amy
Feb 16, 2020  08:02 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi Alfonso,

here is the rh.aparc.DKTatlas.annot file.

Thanks,
Amy
Feb 16, 2020  08:02 PM | Alfonso Nieto-Castanon - Boston University
RE: Problem displaying surface-level analyses
sorry about this, one more iteration yet. I believe the files that you sent me are subject-specific .annot files (resampled to each subject cortical tessellation, and typically located in each subject label folder), please enter in CONN instead (and send me if CONN is not able to load them) the reference lh.aparc*.annot files (defined in fsaverage space, and typically located in freesurfer fsaverage folder). In case of doubt, you can tell whether a particular .annot file is in fsaverage space simply because the number of vertices will be exactly 163842 (in each hemisphere), while subject-specific .annot files have any arbitrary number of vertices. You can check the number of vertices in a freesurfer annotation file using the syntax:

   fname = 'lh.aparc.DKTatlas.annot';
   fp = fopen(fname,'r','b');
   n = fread(fp,1,'int');
   fclose(fp);
   fprintf('%d vertices in %s\n',n,fname);


Best
Alfonso


Originally posted by Amy Bouchard:
Hi Alfonso,

here is the rh.aparc.DKTatlas.annot file.

Thanks,
Amy
Feb 16, 2020  09:02 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi again Alfonso,

all I see are .gcs files. Here is the lh.DKTatlas40.gcs file.

Thanks,
Amy
Attachment: lh.DKTatlas40.gcs
Feb 16, 2020  09:02 PM | Alfonso Nieto-Castanon - Boston University
RE: Problem displaying surface-level analyses
Hi Amy,
Could you please check in $FREESURFER/subjects/fsaverage/label/ folder to see if you can find there the ?h.aparc.DKTatlas.annot files?
Thanks
Alfonso


Originally posted by Amy Bouchard:
Hi again Alfonso,

all I see are .gcs files. Here is the lh.DKTatlas40.gcs file.

Thanks,
Amy
Feb 16, 2020  09:02 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi again Alfonso,

I was able to find the ?h.aparc.annot and ?h.aparc.a2009a.annot files (left and right hemispheres), but not the ?h.aparc.DKTatlas.annot files.

Could this still work?

Thanks,
Amy
Feb 17, 2020  12:02 AM | Alfonso Nieto-Castanon - Boston University
RE: Problem displaying surface-level analyses
Hi Amy,

No problem, just try the attached patch, that should let you load into CONN subject-specific annotation files as well (so you should be able to simply load the same DKTatlas annotation files that you were trying originally, a separate file for each subject, and located in each subject "label" folder). This patch is for release 19b, to install it simply copy the attached file to the conn distribution folder overwriting the file with the same name there

Let me know if you run into any issues
Alfonso

Originally posted by Amy Bouchard:
Hi again Alfonso,

I was able to find the ?h.aparc.annot and ?h.aparc.a2009a.annot files (left and right hemispheres), but not the ?h.aparc.DKTatlas.annot files.

Could this still work?

Thanks,
Amy
Attachment: conn_annot2nii.m
Feb 17, 2020  10:02 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi Alfonso,

thanks so much for the patch. It appears to be working so far.
I will let you know if I run into any issues.

Best,
Amy
Feb 18, 2020  06:02 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi Alfonso,

what should the analysis mask be set to in the setup options folder, for surface-based analyses?

Also, are there any advanced settings for the connectome ring in the ROI to ROI analyses in CONN v. 19b, as in the previous version?

Thanks,
Amy
Feb 19, 2020  06:02 PM | Alfonso Nieto-Castanon - Boston University
RE: Problem displaying surface-level analyses
Hi Amy,

For surface-based analyses the "analysis mask" option is typically set to "explicit mask (mask.surface.brainmask.nii)" (this file is located in conn/utils/surf and it simply masks out the medial/subcortical portions of the cortical surface).

As a side note, do not worry if you have not modified this field from its default value ("explicit mask (mask.volume.brainmask.nii)"). For surface-based analyses (i.e. when the "anaysis space" option in CONN is set to "surface...") CONN will assume that an explicit mask that uses CONN's default "mask.volume.brainmask.nii" file actually refers to the associated CONN's default "mask.surface.brainmask.nii" file instead

Best
Alfonso
Originally posted by Amy Bouchard:
Hi Alfonso,

what should the analysis mask be set to in the setup options folder, for surface-based analyses?

Also, are there any advanced settings for the connectome ring in the ROI to ROI analyses in CONN v. 19b, as in the previous version?

Thanks,
Amy
Feb 19, 2020  07:02 PM | Amy Bouchard
RE: Problem displaying surface-level analyses
Hi Alfonso,

great, thanks very much for all your help!

Best,
Amy

1   2   Next >