matrixToNetwork(
mat,
symmetrizeMethod = c("average", "min", "max"),
signed = TRUE,
min = NULL, max = NULL,
power = 12,
diagEntry = 1)abs(mat).mat. If NULL, the actual attained minimum of mat will be used.
Missing data are ignored. Values below min are truncated to min.mat. If NULL, the actual attained maximum of mat will be used.
Missing data are ignored. Values below max are truncated to max.signed is FALSE, the matrix mat is first converted to its absolute value. This function then symmetrizes the matrix using the symmetrizeMethod component-wise on mat
and t(mat) (i.e., the transpose of mat).
In the next step, the symmetrized matrix is linearly scaled to the interval [0,1] using either min
and max (each either supplied or determined from the matrix). Values outside of the [min, max] range
are truncated to min or max.
Lastly, the adjacency is calculated by rasing the matrix to power.
The diagonal of the result is set to
diagEntry. Note that most WGCNA functions expect the diagonal of an adjacency matrix to be 1.
adjacency for calculation of a correlation network (adjacency) from a numeric matrix such as
expression data adjacency.fromSimilarity for simpler calculation of a network from a symmetric similarity matrix.