getClusterGraph {sccore} | R Documentation |
Collapse vertices belonging to each cluster in a graph
Description
Collapse vertices belonging to each cluster in a graph
Usage
getClusterGraph(
graph,
groups,
method = "sum",
plot = FALSE,
node.scale = 50,
edge.scale = 50,
edge.alpha = 0.3,
seed = 1,
...
)
Arguments
graph |
igraph graph object Graph to be collapsed |
groups |
factor on vertices describing cluster assignment (can specify integer vertex ids, or character vertex names which will be matched) |
method |
string Method to be used, either "sum" or "paga" (default="sum") |
plot |
boolean Whether to show collapsed graph plot (default=FALSE) |
node.scale |
numeric Scaling to control value of 'vertex.size' in plot.igraph() (default=50) |
edge.scale |
numeric Scaling to control value of 'edge.width' in plot.igraph() (default=50) |
edge.alpha |
numeric Scaling to control value of 'alpha.f' in adjustcolor() within plot.igraph() (default=0.3) |
seed |
numeric Set seed via set.seed() for plotting (default=1) |
... |
arguments passed to collapseGraphSum() |
Value
collapsed graph
Examples
cluster.graph = getClusterGraph(conosGraph, igraph::V(conosGraph))
[Package sccore version 1.0.5 Index]