hi,

i have a gold standard in Arabidopsis thaliana( genes and transcription factors and their interaction) like below

TFLocus TargetLocus InteractionType

AT5G10140 AT1G65480 -1

AT5G11260 AT1G27480 -1

AT5G11260 AT5G53370 -1

AT5G11260 AT1G03630 -1

AT5G11260 AT1G13600 -1

AT5G11260 AT2G41670 -1

AT5G11260 AT2G05160 -1

AT5G11260 AT2G40170 -1

AT5G11260 AT1G62780 -1

using this code i have an adjacency matrix

library(igraph)

## Read edge list with weights edge_list <- read.table("Ara_GoldST.txt", header = T, sep = "\t", header=FALSE) ## Form undirected graph from edge list G <- graph.data.frame(edge_list,directed=TRUE) ## Get adjacency matrix ## Set edge weights to values in the InteractionType column by setting A<-as_adjacency_matrix(G,type="both",names=TRUE,sparse=FALSE)

but max(A) is 5 while I need a directed adjacency only contains 0 and 1. how I can get that please?

even i tried

as.directed(G, "mutual") to make my graph directed but my adjacency matrix is undirected and contains 0, 1, 2, 3, 4 and 5 while i only need 0 and 1

thank you for any suggestion

thanks a lot for your help

I did as you mentioned

I used the derived adjacency matrix A as a true net in validate function in minet package to compute confusion matrix with my inferred network (for example derived by aracne),

here is my result

>

Hi,

So you managed to turn the pseudo adjacency matrix returned by

`as_adjacency_matrix()`

into a strict adjacency matrix but now you have a problem when trying to use this matrix with the minet package. So we are done with this thread and you should start a new thread by asking a new question that you need to tag with minet. Otherwise the minet maintainers won't get notified and won't help (what are the chances that they are watching this particular thread which is tagged with igraph?).Thanks,

H.

thank you dear Herve