# INTERACTIVE WIDGETS
devtools::install_github('jjallaire/sigma')
## Downloading github repo jjallaire/sigma@master
## Installing sigma
## "C:/PROGRA~1/R/R-31~1.3/bin/x64/R" --no-site-file --no-environ --no-save \
## --no-restore CMD INSTALL \
## "C:/Users/Rohit/AppData/Local/Temp/RtmpMRSDCS/devtools13d81cc31bd8/jjallaire-sigma-4a8dcfa" \
## --library="C:/Users/Rohit/Documents/R/win-library/3.1" --install-tests
library(sigma)
sigma(system.file("examples/ediaspora.gexf.xml", package = "sigma"))
# Shiny starts ...
library(shiny)
library(sigma)
gexf <- system.file("examples/ediaspora.gexf.xml", package = "sigma")
ui = shinyUI(fluidPage(
checkboxInput("drawEdges", "Draw Edges", value = TRUE),
checkboxInput("drawNodes", "Draw Nodes", value = TRUE),
sigmaOutput('sigma')
))
server = function(input, output) {
output$sigma <- renderSigma(
sigma(gexf,
drawEdges = input$drawEdges,
drawNodes = input$drawNodes)
)
}
# launch Shiny App
shinyApp(ui = ui, server = server)
Shiny applications not supported in static R Markdown documents