robinCompareFastWeight: robinCompareFastWeight

View source: R/ROBINWeighted.R

robinCompareFastWeightR Documentation

robinCompareFastWeight

Description

This function compares two community detection algorithms, from weighted networks. Is the parallelized and faster version.

Usage

robinCompareFastWeight(
  graph,
  method1 = c("walktrap", "edgeBetweenness", "fastGreedy", "leadingEigen", "louvain",
    "spinglass", "labelProp", "infomap", "optimal", "leiden", "other"),
  args1 = list(),
  method2 = c("walktrap", "edgeBetweenness", "fastGreedy", "leadingEigen", "louvain",
    "spinglass", "labelProp", "infomap", "optimal", "leiden", "other"),
  args2 = list(),
  FUN1 = NULL,
  FUN2 = NULL,
  measure = c("vi", "nmi", "split.join", "adjusted.rand"),
  rewire.w.type = "Rewire",
  verbose = TRUE,
  seed = NULL,
  BPPARAM = NULL
)

Arguments

graph

The output of prepGraph.

method1

The first clustering method, one of "walktrap", "edgeBetweenness", "fastGreedy", "louvain", "spinglass", "leadingEigen", "labelProp", "infomap","optimal","leiden".

args1

A list of arguments to be passed to the method1 (see i.e. cluster_leiden for a list of possible method parameters).

method2

The second custering method one of "walktrap", "edgeBetweenness","fastGreedy", "louvain", "spinglass", "leadingEigen", "labelProp", "infomap","optimal","leiden".

args2

A list of arguments to be passed to the method2 (see i.e. cluster_leiden for a list of possible method parameters).

FUN1

personal designed function when method1 is "others". see methodCommunity.

FUN2

personal designed function when method2 is "others". see methodCommunity.

measure

The stability measure, one of "vi", "nmi", "split.join", "adjusted.rand" all normalized and used as distances. "nmi" refers to 1- nmi and "adjusted.ran" refers to 1-adjusted.rand.

rewire.w.type

for weighted graph. Option to rewire one of "Rewire", "Shuffle","Garlaschelli","Sum"

verbose

flag for verbose output (default as TRUE).

seed

set seed (default seed=NULL)

BPPARAM

optional BiocParallel parameter object. If NULL (default), uses parallel::mclapply on Unix/macOS or sequential lapply on Windows. If a BiocParallel object is supplied and the BiocParallel package is installed, it will be used instead.

Value

A list object with two matrices: - the matrix "Mean1" with the means of the procedure for the first method - the matrix "Mean2" with the means of the procedure for the second method


robin documentation built on Nov. 18, 2026, 1:08 a.m.