From 0a1d16508dc7e024261167e298d98ca83ab3c157 Mon Sep 17 00:00:00 2001 From: KristinaMiljkovic Date: Sat, 14 Sep 2024 18:02:53 -0700 Subject: [PATCH 1/2] proposed fix --- R/diffnet-methods.r | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/R/diffnet-methods.r b/R/diffnet-methods.r index 6e0bdc0..109a0f9 100644 --- a/R/diffnet-methods.r +++ b/R/diffnet-methods.r @@ -656,7 +656,7 @@ plot_diffnet.default <- function( #' @return Invisible. A data frame with the calculated coordinates, including: #' `toa`, `threshold`, and `jit` (a jittered version of `toa`). #' @author George G. Vega Yon -plot_threshold <- function(graph, expo, ...) UseMethod("plot_threshold") +plot_threshold <- function(graph, expo, vertex.label,...) UseMethod("plot_threshold") #' @export #' @rdname plot_threshold @@ -679,7 +679,9 @@ plot_threshold.diffnet <- function(graph, expo, ...) { args$toa <- graph$toa } - do.call(plot_threshold.default, c(list(graph = graph$graph, expo=expo), args)) + args$vertex.label <- nodes(graph) + do.call(plot_threshold.default, + c(list(graph = graph$graph, expo=expo), args)) } #' @export From 5c371c384fdc7650b53e26ca8d7b0ea2f8c031c1 Mon Sep 17 00:00:00 2001 From: KristinaMiljkovic Date: Sat, 14 Sep 2024 18:35:00 -0700 Subject: [PATCH 2/2] updated documentation --- man/plot_threshold.Rd | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/man/plot_threshold.Rd b/man/plot_threshold.Rd index 54a2d0f..fcaa4c4 100644 --- a/man/plot_threshold.Rd +++ b/man/plot_threshold.Rd @@ -7,11 +7,11 @@ \alias{plot_threshold.default} \title{Threshold levels through time} \usage{ -plot_threshold(graph, expo, ...) +plot_threshold(graph, expo, vertex.label, ...) -\method{plot_threshold}{diffnet}(graph, expo, ...) +\method{plot_threshold}{diffnet}(graph, expo, vertex.label, ...) -\method{plot_threshold}{array}(graph, expo, ...) +\method{plot_threshold}{array}(graph, expo, vertex.label, ...) \method{plot_threshold}{default}( graph,