R/list2arr0.R

Defines functions list2arr0

list2arr0 <-
function(network){
lvec<-unlist(lapply(network,length))

net<-matrix(0,sum(lvec),2)
net[,1]<-rep(names(network),lvec)
net[,2]<-unlist(network)

links= paste(net[,1], net[,2], sep=' ')
ulinks= unique(links)

return(ulinks)
}

Try the neaGUI package in your browser

Any scripts or data that you put into this service are public.

neaGUI documentation built on May 2, 2019, 5:41 p.m.