Marmello77

Cores

> MA <- fromJSON("https://raw.githubusercontent.com/bavla/ibm3m/master/data/marmello77.json")
> str(MA)

> n1 <- nrow(MA$nodes$an); n2 <- nrow(MA$nodes$pl)
> C1 <- 1:n1; C2 <- 1:n2
> San <- sapply(1:n1,function(u) pSum(MA,u,C2,"an","pl",weight="w"))
> Spl <- sapply(1:n2,function(v) pSum(MA,v,C1,"pl","an",weight="w"))

> PSum <- function(MN,u,C,way1,way2,...) pSum(MN,u,C,way1,way2,weight="w",...)
> cores <- Gen2modeCore(MA,"an","pl",PSum,PSum,5,10)
> report2modeCore(MA,"an","pl",PSum,PSum,cores,short=50)

> cores <- Gen2modeCore(MA,"an","pl",PSum,PSum,10,15)
> report2modeCore(MA,"an","pl",PSum,PSum,cores,short=50)
> # t1=144 t2=19
> Cna <- cores$core1; Cpl <- cores$core2
> San <- sapply(1:n1,function(u) pSum(MA,u,Cpl,"an","pl",weight="w"))
> Spl <- sapply(1:n2,function(v) pSum(MA,v,Can,"pl","an",weight="w"))
> anCore <- San[Cna]
> plCore <- Spl[Cpl]
> names(anCore) <- MA$nodes$an$ID[Cna]
> names(plCore) <- MA$nodes$pl$ID[Cpl]
> anCore
CerSub DidAur NecLas 
   159    183    249 
> plCore
CamAda CecGla CecPac CocAur LeaAur MicLig MorSp7 MorSp8 MorSp9 MyrSp2 PsidSp 
    21     30     41     29     30     55     56     82    131     19     46 
vlado/work/2m/mwn/ex/ma77.txt · Last modified: 2023/01/25 05:41 by vlado
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Noncommercial-Share Alike 3.0 Unported
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki