- qx_mri.fc.fc_compute_roifc(bolds, roiinfo, frames, targetf, options)#
fc_compute_roifc(bolds, roiinfo, frames, targetf, options)
Computes ROI functional connectivity matrices for individual subject / session.
- --bolds (str):
A string with a pipe separated list of paths to .conc or bold files. The first element has to be the name of the file or group to be used when saving the data. E.g.: 'rest|<path to rest file 1>|<path to rest file 2>'.
- --roiinfo (str):
A path to the names file specifying group based ROI. Additionaly, separated by a pipe '|' symbol, a path to an image file holding subject/session specific ROI definition.
- --frames (cell array | int | str, default ''):
The definition of which frames to extract, specifically
a numeric array mask defining which frames to use (1) and which not (0), or
a single number, specifying the number of frames to skip at the start of each bold, or
a string describing which events to extract timeseries for, and the frame offset from the start and end of the event in format:
'<fidlfile>|<extraction name>:<event list>:<extraction start>:<extraction end>'
is a path to the fidle file that defines the events
- extraction name
is the name for the specific extraction definition
- event list
is a comma separated list of events for which data is to be extracted
- extraction start
is a frame number relative to event start or end when the extraction should start
- extraction end
is a frame number relative to event start or end when the extraction should start the extraction start and end should be given as '<s|e><frame number>'. E.g.:
's0' ... the frame of the event onset
's2' ... the second frame from the event onset
'e1' ... the first frame from the event end
'e0' ... the last frame of the event
'e-2' ... the two frames before the event end.
- --targetf (str, default '.'):
The folder to save images in.
- --options (str, default 'roimethod=mean|eventdata=all|ignore=use,fidl|badevents=use|fcmeasure=r|saveind=none|verbose=false|debug=false|fcname='):
A string specifying additional analysis options formated as pipe separated pairs of colon separated key, value pairs:
It takes the following keys and values:
What method to use to compute ROI signal:
Defaults to 'mean'.
What data to use from each event:
use all identified frames of all events
use the mean across frames of each identified event
use the minimum value across frames of each identified event
use the maximum value across frames of each identified event
use the median value across frames of each identified event.
Defaults to 'all'.
A comma separated list of information to identify frames to ignore, options are:
ignore frames as marked in the use field of the bold file
ignore frames as marked in .fidl file (only available with event extraction)
the column name in ∗_scrub.txt file that matches bold file to be used for ignore mask.
Defaults to 'use,fidl'.
What to do with events that have frames marked as bad, options are:
use any frames that are not marked as bad
use the frames that are not marked as bad if at least <number> ok frames exist
if any frame is marked as bad, ignore the full event.
Defaults to 'use'.
Which functional connectivity measure to compute, the options are:
Pearson's r value
Defaults to 'r'.
A comma separted list of formats to use to save the data:
save the resulting data in a long format .txt file
save the resulting data in a matlab .mat file
don't save the results in a file, same as ''.
Defaults to 'none'.
An optional name describing the functional connectivity computed to add to the output files, if empty, it won't be used. Defaults to ''.
An optional subject/session name to add to the output files, if empty, it won't be used. Defaults to ''.
Whether to be verbose when running the analysis:
Defaults to 'false'.
Whether to print debug when running the analysis:
Defauts to 'false'.
The title of the extraction as specifed in the frames string, empty if extraction was specified using a numeric value.
A cell array with the names of the ROI used in the order of columns and rows in the functional connectivity matrix.
Number of frames over which the matrix was computed.
Correlation matrix between all ROI for that subject/session.
Fisher z transformed correlation matrix between all ROI for that subject/session.
z-scores for the correlations.
p-values for the correlations.
Covariance matrix between all ROI for that subject/session.
Please note, that cv will only be present if it was specified as the cmeasure. r, fz, z, p will only be present if r was specified as the fcmeasure.
Based on saveind option specification a file may be saved with the functional connectivity data saved in a matlab.mat file and/or in a text long format: