Skip to content

Commit

Permalink
Add initial plot controls to app
Browse files Browse the repository at this point in the history
  • Loading branch information
EeethB committed Sep 13, 2023
1 parent 39450d6 commit 1a6d8b5
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions app/app.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
library(shiny)
library(igraph)
library(graphicalMCP)

ui <- fluidPage(
Expand All @@ -7,7 +8,11 @@ ui <- fluidPage(
titlePanel("Graphical Multiple Comparison Procedures"),

fluidRow(
column(6, plotOutput("graphPlot"))
column(6, plotOutput("graphPlot")),
column(
6,
selectInput("layout", "Graph layout", c("grid", layout_nicely))
)
),

hr(),
Expand Down Expand Up @@ -129,8 +134,14 @@ server <- function(input, output, session) {
clean_hypotheses,
clean_transitions
)
browser()
if (input$layout != "grid") {
layout <- as.function(input$layout)
} else {
layout <- input$layout
}

plot(graph)
plot(graph, layout = layout)
})
}

Expand Down

0 comments on commit 1a6d8b5

Please sign in to comment.