Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

visNetworkEditor-module

Module shiny for visualize and customize and get back a visNetwork object. Using the javascript interface visConfigure.


Description

Module shiny for visualize and customize and get back a visNetwork object. Using the javascript interface visConfigure.

Usage

visNetworkEditorServer(
  input,
  output,
  session,
  object,
  filter = shiny::reactive(NULL),
  showButton = shiny::reactive(NULL)
)

visNetworkEditorUI(id, quitButton = FALSE, height = "700px")

Arguments

input

list shiny input

output

list, shiny output

session

list, shiny session

object

a visNetwork object. Must be a reactive.

filter

: see visConfigure. Must be a reactive.

showButton

: see visConfigure. Must be a reactive.

id

character id of module, linked to visNetworkEditorUI

quitButton

: logical. Add a button for quit shiny and get back network in R ?

height

: height of the configuration div. Defaut to "700px"

References

See Also

Examples

## Not run: 

nodes <- data.frame(id = 1:3, label = paste("Node", 1:3))
edges <- data.frame(from = c(1,2), to = c(1,3), label = paste("Edge", 1:2))
network <- visNetwork(nodes, edges)

shiny::shinyApp(ui = shiny::fluidPage(
 visNetworkEditorUI(id = "id1")), 
 server = function(input, output, session) {
 shiny::callModule(visNetworkEditorServer, "id1", object = shiny::reactive(network))
})


## End(Not run)

visNetwork

Network Visualization using 'vis.js' Library

v2.0.9
MIT + file LICENSE
Authors
Almende B.V. [aut, cph] (vis.js library in htmlwidgets/lib, http://visjs.org, http://www.almende.com/home), Benoit Thieurmel [aut, cre] (R interface), Titouan Robert [aut, ctb]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.