help > RE: Explanation of Outputs
Sep 26, 2016  06:09 PM | Pravesh Parekh - National Institute of Mental Health and Neurosciences
RE: Explanation of Outputs
Hi Kevin,

I will try and be as comprehensive as possible here, though its possible that I might miss out on some of the names/naming convention. Most of these have been addressed at various places on this forum before and I have linked some of the forum posts which I have personally kept track of/asked at/replied to (though there might be other threads with similar content):

Let's say your structural scan is named "t1.nii".

Upon preprocessing, the files are stored in the same folder from which it is read. They are named as follows (borrowed from here):

ct1 ---> centered T1
c1ct1 ---> segmented centered T1 (grey matter mask)
c2ct1 ---> segmented centered T1 (white matter mask)
c3ct1 ---> segmented centered T1 (CSF)
centering_t1.mat ---> contains the rotation matrix applied to center (bring the origin closer to ACPC plane)
ct1_seg8.mat ---> matrix generated while segmentation module was running. If you load it in MATLAB, you would see several variables in your workspace. They include, among other things, the original image, warping parameters, rotation matrix, the location for the TPMs, etc.
uxxx.nii ---> unwarped
auxxx.nii ---> slice timing corrected, unwarped
wauxxx.nii ---> normalized, slice timing corrected, unwarped
swauxxx.nii ---> smoothed, normalized, slice timing corrected, unwarped
rp_xxx file ---> output from realignment step
y_ and iy_ are the deformation fields (instead of the older sn_.mat files), "which contain three image volumes encoding the x, y and z coordinates (in mm) of where each voxel maps to" (SPM 12 release notes). You would have these for structural and functional images.


When you open your Conn project folder there are two folders: data and results.

Data folder:

COND_Subjectxxx_Sessionxxx.mat files ---> most likely (not sure) contains the HRF weights for each condition

COV_subjectxxx_Sessionxxx.mat:
data: cell type containing realignment parameters, scrubbing parameters, and main effects of the condition(s) (in that order; "names" cell contains the names of these)

DATA_Subjectxxx_Sessionxxx.mat ---> image properties like bounding box, number of voxels, voxel size, etc.

REX_Subjectxxx_ROIx.mat ---> time series from different ROIs (name of the ROI is mentioned inside the params structure), including the number of PCA components to be extracted from each of the ROIs (params.ROIdata would have the time series from that ROI)

ROI_Subjectxxx_Sessionxxx.mat:
data: time series from ALL ROIs (including WM/CSF etc)
names: the names (in order) of the ROIs mentioned in the data field
xyz: the x, y, and z coordinates of the ROIs


In the Results/preprocessing folder:
_list_conditions: names of the conditions

DATA_Subjectxxx_Conditionxxx,mat ---> voxel level data post denoising

niftiDATA_Subjectxxx_Conditionxxx.nii ---> nifti file after denoising [check this forum post]

ROI_Subejctxxx_Conditionxxx: same as above, but data is after denoising


In the Results/firstlevel folder: ANALYSIS_** refers to the analysis number (right side in the first level analyses Conn GUI; you can run multiple analyses on the same set of subjects without having to do the same steps again. For example: using correlation coefficient, and semi partial correlation as different analyses).

Inside each ANALYSIS_xx folder:
_list_conditions: names of conditions
_list_sources: names of the sources (note that WM/CSF et al are not included, unlike before)
_list_sources: the same, with the full ROI name corresponding to the source number
BETA_Subjectxxx_Conditionxxx_Sourcexxx.nii: nifti files for each source (i.e. ROI), each condition, each session, each subject (the BETA would be based on your analysis choice.

Each resultsROI_Subjectxxx_Conditionxxx.mat file contains the following fields:
DOF: degrees of freedom
names: names of source ROIs
names2: names of target ROIs (note that Grey Matter is included as a target, hence number of names2 elements = number of names elements+1)
regressors: if you are using higher order time series derivatives etc. (not too sure about this)
SE: (most likely) the standard error
xyz: x, y, and z coordinates of each "target" ROI (Grey Matter is still included)
Z: Fisher transformed correlation coefficients (from each source to each target; could be a different value depending on the choice of analysis)

se_Subjectxxx_Conditionxxx.nii: no idea about this file (sorry!; some first level map maybe?)

For results/secondlevel folder (again, different ANALYSIS_xx folders): If you have defined contrast(s), they will have folders of their own inside the ANALYSIS folder. Each contrast folder has a "condition" folder inside (or condition contrast folder):

ROI.mat: contains the following fields: (borrowed from here):
- xX has the details of the subjects selected
- y has the correlation values of all subjects (if correlation is the measure of functional connectivity selected at first level)
- names has the names of the source ROIs
- xyz has centroid of the source ROI
- names2 has the names of target ROIs
- xyz2 has centroids of traget ROIs
- h is the average of the y values for the particular pair of ROIs (essentially, the beta displayed in the results window)
- F has the appropriate statistical value (T value for example)
- p has the one sided uncorrected p value
- dof is the degrees of freedom
- statname is the name of statistic being calculated (T/F)

Note that the p value is just one sided and not corrected for multiple comparison. Use p_twosided = 2*min(p_onesided, 1-p_onesided) to convert to two sided p values (also, check this post for a discussion on how to do FDR correction by calling conn_fdr).
Also, check this post for some more insight on this ROI.mat variable and the calculation of error bars, etc. 


From your post, I think you are trying to extract denoised time series. Here is a quick compilation of some related posts about the same:

conn*/results/preprocessing/ROI_Subject*_Condition*.mat will give you the denoised time series. Then, condition specific time series can be obtained by:

w = max(0,conditionweights{1});
idx = find( w>0 );
data_reduced = cellfun(@(x)x(idx,:), data, 'uni',0);
w_reduced = w(idx);

"data_reduced" and "w_reduced" variables represent, respectively, the timeseries and weights that will be used for computing weighted-GLM measures (e.g. weighted correlation) [check this post]

Finally, weighted_ts = conn_wdemean(data_reduced, w_reduced).*w_reduced;

You can then calculate correlation coefficients (for example) between all the weighted_ts (followed by Fisher's transform: atanh). 


Hope the above helps!


P.S: Do note that not all files mentioned above would be available on default run. Most of the REX and .nii files are optional output (for example, this post).

Best,
Pravesh

Threaded View

TitleAuthorDate
Kevin Mann Sep 26, 2016
David Fischer Dec 30, 2020
RE: Explanation of Outputs
Pravesh Parekh Sep 26, 2016
Sebastian Speer Nov 26, 2019
Daniel Berge Dec 16, 2017
Alfonso Nieto-Castanon Sep 27, 2016
Jason Craggs Sep 15, 2017
Alfonso Nieto-Castanon Sep 16, 2017
Pravesh Parekh Sep 16, 2017
Anant Shinde Sep 14, 2017
Kevin Mann Sep 26, 2016