-
Notifications
You must be signed in to change notification settings - Fork 0
/
ui.R
42 lines (35 loc) · 1.32 KB
/
ui.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
library(shiny)
# Define the overall UI
shinyUI(
fluidPage(
titlePanel("MIMIC Patient Viewer"),
# 1. Patient Table -------------------------------------------------
fluidRow(
DT::dataTableOutput("mainTable")
),
fluidRow(
#once patients are selected this action button is what triggers
#the program to retrieve their recorded events and plot it in the
#events table.
actionButton("getEvents","Retreive Events for Selected Patients")
),
# 2. Event Table ---------------------------------------------------
fluidRow(
#here we use uiOutput which allows for output formats to change dyanmically.
#So we could output text, a table, an image or whatever we need to.
#If no patients are selected there should be events and hence no events
#table to show. Otherwise we should output a table.
uiOutput("eventTableUi")
),
# 3. Main Plotting Area --------------------------------------------
sidebarLayout(
# If no patients and events are selected, we don't want anything output here.
#Otherwise we do want the plotting options shown.
uiOutput("plotOptionsUi"),
#this is where the main plot of the program actually goes.
mainPanel(
plotOutput('mainPlot',width="100%")
)
)
)
)