summaryrefslogtreecommitdiff
path: root/R/networkplot.R
diff options
context:
space:
mode:
authorChris Sobczak <chris@sobczak.family>2026-06-15 18:19:35 -0700
committerChris Sobczak <chris@sobczak.family>2026-06-15 18:19:35 -0700
commite5071ae6091eafc4a98bc280a23349dcb2261da3 (patch)
tree2a7bcc84687a6d82e064e76a63539c066324b23c /R/networkplot.R
parentc22a8c7b71a54d3c604fef8ab68a10b50e3178cd (diff)
Add sizing and fix legend
Diffstat (limited to 'R/networkplot.R')
-rw-r--r--R/networkplot.R14
1 files changed, 1 insertions, 13 deletions
diff --git a/R/networkplot.R b/R/networkplot.R
index 9d251ea..10dfc01 100644
--- a/R/networkplot.R
+++ b/R/networkplot.R
@@ -14,17 +14,6 @@
#'
#' @return A ggraph object
#'
-#' @examples
-#' X <- matrix(data = rnorm(100), nrow = 10)
-#' R <- cor(X)
-#' networkplot(R, title = 'Example Correlation Plot')
-#' colnames(R) <- as.character(seq_len(ncol(R)))
-#' g <- data.frame(
-#' node = colnames(R),
-#' group = rep(c('A', 'B'), length.out = ncol(R))
-#' )
-#' networkplot(R, groups = g, title = 'Example Correlation Plot')
-#'
#' @import ggraph
#' @import igraph
#'
@@ -152,8 +141,7 @@ networkplot <- function(R, groups = NULL, group_label = NULL, title = NULL, r_la
high = 'blue',
midpoint = 0,
limits = c(-1, 1),
- name = r_label,
- guide = ggplot2::guide_colourbar()
+ name = r_label
) +
# operates on node data from the layout
# leaf is a logical vector (provided by the ggraph object g)