vectorizeFC.Rd
vectorizing and concatenating and M x M matrices
vectorizeFC(
FC_dir,
filename = "FCmat.rds",
task,
fisherz = TRUE,
timeseries = FALSE
)
the directory containing the M x M matrices (saved as .csv files)
the output format of the concatenated group level matrix. Only filenames with the *.csv or *.rds extensions are accepted. The .rds format uses less disk space. Set to 'FCmat.rds' by default
A string to select the .csv files with a specific taskname.
TRUE
or FALSE
option specifying if the edge values should undergo a fisher-Z transformation. This would be applicable in cases and functional connectivity is calculated as a pearson's correlation coefficient. Set to TRUE
by default.
TRUE
or FALSE
option specifying if the parcellated timeseries are used as inputs. Set to FALSE
by default.
Depending on whether a filename with a .csv or .rds file extension is specified, outputs a .csv file containing the N x ((M x M)-M)/2 matrix or a .rds file containing a list object: 1)N x ((M x M)-M)/2 matrix, 2) a vector of subject IDs.
This function reads the M x M matrices (saved as .csv files) in a directory, vectorizes and concatenates them into a single N x ((M x M)-M)/2 matrix. N= number of subjects; M=number of nodes in the connectome
if (FALSE) {
vectorizeFC(FC_dir="FCmat", filename="FCmat.rds", fisherz=TRUE)
}