string2mat {BiDAG} | R Documentation |
Deriving interactions matrix
Description
This transforms a list of possible interactions between proteins downloaded from STRING database into a matrix which can be used for blacklisting/penalization in BiDAG.
Usage
string2mat(curnames, int, mapping = NULL, type = c("int"), pf = 2)
Arguments
curnames |
character vector with gene names which will be used in |
int |
data frame, representing a interactions between genes/proteins downloaded from STRING (https://string-db.org/); two columns are necessary 'node1' and 'node2' |
mapping |
(optional) data frame, representing a mapping between 'curnames' (gene names, usually the column names of 'data') and gene names used in interactions downloaded from STRING (https://string-db.org/); two columns are necessary 'queryItem' and 'preferredName' |
type |
character, defines how interactions will be reflected in the output matrix; |
pf |
penalization factor for interactions, needed if |
Value
square matrix whose entries correspond to the list of interactions and parameter type
Examples
curnames<-colnames(kirp)
intmat<-string2mat(curnames, mapping, interactions, type="pf")