From f6ad1226f324bdd9912a90b5428cb7d0383e6cca Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 20 Apr 2026 09:41:46 +0000 Subject: [PATCH] docs: AI-generated doc upgrade for `exportNetworkToHTML` Auto-generated by weekly doc workflow. Target: R/exportNetworkToHTML.R::exportNetworkToHTML Date: 2026-04-20T09:41:46Z --- R/exportNetworkToHTML.R | 35 +++++++++++++++++++++++++++-------- 1 file changed, 27 insertions(+), 8 deletions(-) diff --git a/R/exportNetworkToHTML.R b/R/exportNetworkToHTML.R index bda111b..5e53a23 100644 --- a/R/exportNetworkToHTML.R +++ b/R/exportNetworkToHTML.R @@ -1,13 +1,31 @@ -#' Export network data with Cytoscape visualization +```r +#' Export Network Data to HTML with Cytoscape Visualization #' -#' Convenience function that takes nodes and edges data directly and creates -#' both the configuration and HTML export in one step. +#' @description +#' This function facilitates the export of network data to an HTML file with +#' an embedded Cytoscape visualization. It combines the creation of the +#' network configuration and the HTML export into a single step. +#' +#' @param nodes A \code{data.frame} containing the nodes of the network. +#' Each row represents a node with at least an \code{id} column. +#' @param edges A \code{data.frame} containing the edges of the network. +#' Each row represents an edge with at least \code{source} and \code{target} columns. +#' @param filename A \code{character} string specifying the output HTML filename. +#' Defaults to \code{"network_visualization.html"}. +#' @param displayLabelType A \code{character} string indicating the type of label +#' to display on nodes. Defaults to \code{"id"}. +#' @param nodeFontSize A \code{numeric} value specifying the font size of node labels. +#' Defaults to \code{12}. +#' @param ... Additional arguments passed to \code{exportCytoscapeToHTML()}. +#' +#' @return Invisibly returns the file path of the created HTML file. +#' +#' @examples +#' nodes <- data.frame(id = c("Node1", "Node2", "Node3")) +#' edges <- data.frame(source = c("Node1", "Node2"), target = c("Node2", "Node3")) +#' exportNetworkToHTML(nodes, edges, filename = "my_network.html") #' -#' @inheritParams cytoscapeNetwork -#' @param filename Output HTML filename -#' @param ... Additional arguments passed to exportCytoscapeToHTML() #' @export -#' @return Invisibly returns the file path of the created HTML file exportNetworkToHTML <- function(nodes, edges, filename = "network_visualization.html", displayLabelType = "id", @@ -65,4 +83,5 @@ previewNetworkInBrowser <- function(nodes, edges, } invisible(temp_file) -} \ No newline at end of file +} +``` \ No newline at end of file