define_modules: Functions to define Sponge modules, created as all the first...

View source: R/fn_spongeffects_utility.R

define_modulesR Documentation

Functions to define Sponge modules, created as all the first neighbors of the most central genes (= centrality), or with community detection methods (louvain, leiden, walktrap, optimal).

Description

Functions to define Sponge modules, created as all the first neighbors of the most central genes (= centrality), or with community detection methods (louvain, leiden, walktrap, optimal).

Usage

define_modules(
  network,
  central.modules = F,
  remove.central = T,
  set.parallel = T,
  module_creation = "centrality",
  param
)

Arguments

network

Network as dataframe and list of central nodes. First two columns of the dataframe should contain the information of the nodes connected by edges.

central.modules

consider central gene as part of the module. Is ignored if community detection is used for module creation. (default: False)

remove.central

Possibility of keeping or removing (default) central genes in the modules (default: T)

set.parallel

paralleling calculation of define_modules() (default: F)

module_creation

c("centrality", "louvain", "leiden", "walktrap", "optimal") Which method should be used to create modules (default: "centrality")

param

Is used to refine the community detection methods. Will influence the resolution parameter for the louvain or leiden algorithm and the steps parameter in the walktrap algorithm.

Value

List of modules. Module names are the corresponding central genes.


mlist/SPONGE documentation built on Feb. 12, 2023, 1:22 a.m.