Sorry for the confusion. Locally acquired data wasn't processed using the HCP pipelines, it is in a different resolution and it was processed in volume space, no problem there.
I want to use Choi's parcellation with HCP data. All the process I described is mi workaround to adapt Choi files to HCP files. Jaime El lun., 27 may. 2019 22:12, Glasser, Matthew <glass...@wustl.edu> escribió: > I thought you said you were using a locally collected sample you ran the > HCP Pipelines on? > > Matt. > > > > *From: *Jaime Caballero <jcabai...@gmail.com> > *Date: *Monday, May 27, 2019 at 3:10 PM > *To: *"Glasser, Matthew" <glass...@wustl.edu> > *Subject: *Re: [HCP-Users] Convert nifti-ROIs to cifti format > (subcortical) > > > > Ok, thank you! I will try that. > > > > I asume the reference image > ${StudyFolder}/${Subject}/MNINonLinear/ROIs/Atlas_ROIs.2.nii.gz is to be > downloaded with the structural package? > > > > Regards, > > Jaime > > > > El lun., 27 may. 2019 a las 21:00, Glasser, Matthew (<glass...@wustl.edu>) > escribió: > > To make the .dscalar.nii file, you seem to be on the right track. If the > Choi ROIs are properly in MNI space, hopefully you could simply use > applywarp --interp=nn -i <ROIs.nii.gz> -r > ${StudyFolder}/${Subject}/MNINonLinear/ROIs/Atlas_ROIs.2.nii.gz -o > <ROIs.2.nii> and then the wb_command -cifti-create-dense-from-template you > mention. > > > > Matt. > > > > *From: *Jaime Caballero <jcabai...@gmail.com> > *Date: *Monday, May 27, 2019 at 12:56 PM > *To: *"Glasser, Matthew" <glass...@wustl.edu> > *Cc: *"hcp-users@humanconnectome.org" <hcp-users@humanconnectome.org> > *Subject: *Re: [HCP-Users] Convert nifti-ROIs to cifti format > (subcortical) > > > > The objective is to extract functional connectivity between cortical and > striatal ROIs, and ALFF and ReHo from both cortical and striatal ROIs. > > > > Up to this point I have imported each subject's dtseries.nii file into > MATLAB, and also the previously defined ROIs in an HCP-compatible format. > For the dtseries I have a 96854x1200 matrix, and for the ROI a 96854x1 > matrix containing a mask, which I use to extract the time series I'm > interested in for further processing. > > > > Jaime > > > > > > El lun., 27 may. 2019 a las 19:14, Glasser, Matthew (<glass...@wustl.edu>) > escribió: > > What do you plan to do with the file? > > > > Matt. > > > > *From: *Jaime Caballero <jcabai...@gmail.com> > *Date: *Monday, May 27, 2019 at 12:08 PM > *To: *"Glasser, Matthew" <glass...@wustl.edu> > *Cc: *"hcp-users@humanconnectome.org" <hcp-users@humanconnectome.org> > *Subject: *Re: [HCP-Users] Convert nifti-ROIs to cifti format > (subcortical) > > > > A .dscalar.nii output, I think. Basically I want an equivalent of the > nifti ROI, but in cifti: for each voxel/vertex, value 1 if inside the ROI, > 0 if outside. Would a dlabel file be better for this application? > > > > El lun., 27 may. 2019 a las 19:03, Glasser, Matthew (<glass...@wustl.edu>) > escribió: > > Are you wanting a .dlabel.nii output or a .dscalar.nii output? > > > > Matt. > > > > *From: *<hcp-users-boun...@humanconnectome.org> on behalf of Jaime > Caballero <jcabai...@gmail.com> > *Date: *Monday, May 27, 2019 at 10:37 AM > *To: *"hcp-users@humanconnectome.org" <hcp-users@humanconnectome.org> > *Subject: *[HCP-Users] Convert nifti-ROIs to cifti format (subcortical) > > > > Dear experts > > > > In my center we are studying cortico-striatal functional connectivity, and > cortical/striatal local measures (ALFF, ReHo) on a locally acquired sample. > For that we are using Choi's functional parcellation, distributed as a > volumetric NIFTI file, in MNI152 space. We want to validate our measures > with a subset of the S1200 release (resting state, 3T). Specifically I have > used the ICA-FIX cleaned and MSM-all registered files, i.e.: > > > <subject_dir>/MNINonLinear/Results/rfMRI_REST1_LR/rfMRI_REST1_LR_Atlas_MSMAll_hp2000_clean.dtseries.nii > > > > The thing is I have doubts on the way to convert nifti ROIs to cifti > format in this case. > > > > My first approach: > > > > 1. Load a cifti template file and the NIFTI ROI file in MATLAB. The roi > file is a volume containing 0s and 1s. > > 2. Use the inverse of the NIFTI's transformation matrix to convert the XYZ > coordinates in MNI space from each grayordinate to XYZ coordinates in the > NIFTI'S volume space. (The matrix is corrected to account for MATLAB's > 1-based matrix indexing) > > 3. The values of the NIFTI volume for the obtained coordinates define the > ROI in the output cifti. > > 4. Keep only the grayordinates that are set to one by my method and that > are labeled as striatum (i.e. caudate, putamen or accumbens) in the cifti > files. > > > > This aproach is rather hand-made, and I wonder if I am missing something > important. Conceptually it looks correct to me, but the ROIs appear > slightly displaced to the right, which might affect the results. > > To load the CIFTIs I use fieltdrip's ft_cifti_read( ), which for this > purpose works well (it reads the grayordinate positions and labels), and to > load the NIFTIs I use Freesurfer's load_nifti( ). > > Is this method correct, or is there something important I'm not taking > into account? > > > > Now I'm trying to do the same with wb_command to compare, but I cannot get > it working. The procedure I use is: > > > > # Resample the ROI file to 2x2x2 resolution with ANTs: > > ResampleImage 3 "$NiftiFileIn" "$NiftiFileResampled" 2x2x2 0 > > # Convert the obtained nifti to cifti: > > wb_command -cifti-create-dense-from-template "$CiftiDscalarTemplateFile" > "$CiftiOut" -volume-all "$NiftiFileResampled" > > > > Which outputs the error: -volume-all specifies a volume file that doesn't > match the volume space of the template cifti file > > Is there anything wrong with my way of doing this procedure? > > > > Thanks in advance, > > > > Best regards, > > Jaime Caballero-Insaurriaga > > _______________________________________________ > HCP-Users mailing list > HCP-Users@humanconnectome.org > http://lists.humanconnectome.org/mailman/listinfo/hcp-users > > > ------------------------------ > > The materials in this message are private and may contain Protected > Healthcare Information or other information of a sensitive nature. If you > are not the intended recipient, be advised that any unauthorized use, > disclosure, copying or the taking of any action in reliance on the contents > of this information is strictly prohibited. If you have received this email > in error, please immediately notify the sender via telephone or return mail. > > > ------------------------------ > > The materials in this message are private and may contain Protected > Healthcare Information or other information of a sensitive nature. If you > are not the intended recipient, be advised that any unauthorized use, > disclosure, copying or the taking of any action in reliance on the contents > of this information is strictly prohibited. If you have received this email > in error, please immediately notify the sender via telephone or return mail. > > > ------------------------------ > > The materials in this message are private and may contain Protected > Healthcare Information or other information of a sensitive nature. If you > are not the intended recipient, be advised that any unauthorized use, > disclosure, copying or the taking of any action in reliance on the contents > of this information is strictly prohibited. If you have received this email > in error, please immediately notify the sender via telephone or return mail. > > > ------------------------------ > > The materials in this message are private and may contain Protected > Healthcare Information or other information of a sensitive nature. If you > are not the intended recipient, be advised that any unauthorized use, > disclosure, copying or the taking of any action in reliance on the contents > of this information is strictly prohibited. If you have received this email > in error, please immediately notify the sender via telephone or return mail. > _______________________________________________ HCP-Users mailing list HCP-Users@humanconnectome.org http://lists.humanconnectome.org/mailman/listinfo/hcp-users