make_annotations {EGAD} | R Documentation |
The function annotates a list of genes according to a given ontology. It creates a binary matrix associating genes (rows) with labels (columns).
make_annotations(data, listA, listB)
data |
2-column matrix, each row a pair indicating a relationship or interaction |
listA |
string array of genes |
listB |
string array of labels/functions |
net matrix binary
gene.list <- paste('gene', 1:100, sep='') labels.list <- paste('labels', 1:10, sep='') data <- matrix(0,nrow=100, ncol=2) data[,1] <- sample(gene.list, 100, replace=TRUE) data[,2] <- sample(labels.list, 100, replace=TRUE) net <- make_annotations(data, gene.list, labels.list)