plot_graph.Rd
Plot the geneset kNN network as a graph.
# S3 method for BOWER plot_graph( bower, colorby = "cluster", mode = c("default", "gsea"), gsea.slot = c("padj", "pval", "NES", "ES"), gsea.pval.cutoff = 0.25, node.size = "geneset_size", node.label = "labels", node.label.size = 3, title = NULL, title.size = 3, edge.width = "weight", edge.width.thickness.range = c(0, 1), edge.alpha = 0.25, dot_max = 8, guides.colour = FALSE ) # S3 method for igraph plot_graph( gr, colorby = "cluster", node.size = "geneset_size", node.label = "labels", node.label.size = 3, title = NULL, title.size = 3, edge.width = "weight", edge.width.thickness.range = c(0, 1), edge.alpha = 0.25, dot_max = 8, guides.colour = FALSE, ... )
bower | BOWER object |
---|---|
colorby | name of attribute for colors of nodes. |
node.size | name of attribute for size of nodes or numerical value/vector. |
node.label | name of attribute for colors of nodes. |
node.label.size | size of node label. |
edge.width | name of attribute for width of edges. |
edge.width.thickness.range | scale for range of widths of edges. |
edge.alpha | transparency of edges. |
guides.colour | boolean. whether or not to display guide for vertex colour. |
... | passed to ggraph::ggraph |
node.max_size | maximum node size. |
Returns a ggraph plot.
Just a ggraph wrapper to plot the graph.
gmt_file <- system.file("extdata", "h.all.v7.4.symbols.gmt", package = "bowerbird") bwr <- bower(gmt_file) bwr <- snn_graph(bwr) bwr <- find_clusters(bwr) bwr <- summarize_clusters(bwr, ncpus = 1) plot_graph(bwr) #> Warning: `guides(<scale> = FALSE)` is deprecated. Please use `guides(<scale> = "none")` instead. #> Warning: Removed 41 rows containing missing values (geom_text).