ui = navbarPage(title = 'Normal Distribution',
collapsible = T,
position = 'fixed-top',
theme = shinythemes::shinytheme('flatly'),
shiny::includeCSS('www/custom.css'),
tabPanel('Distribution Functions',
uiOutput('norfunc')),
tabPanel('Distribution Properties',
uiOutput('norprops')),
tabPanel('Shiny App',
sidebarPanel(width = 3,
hr(),
sliderInput("range.n",
label = "Range",
min = -20,
max = 20,
value = c(-4,4)),
hr(),
sliderInput("mu.n",
label = HTML("Mean (μ)"),
min = -3,
max = 3,
step = 0.5,
value = 0,
animate = T),
hr(),
sliderInput("sig.n",
label = HTML("Std Dev (σ)"),
min = 0.5,
max = 5,
step = 0.5,
value = 1,
animate = T)),
mainPanel(width = 9,
tabsetPanel(type = 'pills',
tabPanel('Distribution Function',
metricsgraphicsOutput(height = "550px", "norC")),
tabPanel('Density',
metricsgraphicsOutput(height = "550px", "norP")),
tabPanel('Survival',
metricsgraphicsOutput(height = "550px", "norR")),
tabPanel('Hazard',
metricsgraphicsOutput(height = "550px", "norh")),
tabPanel('Cumulative Hazard',
metricsgraphicsOutput(height = "550px", "norH")),
tabPanel('Quantile',
metricsgraphicsOutput(height = "550px", "norQ"))))
),
tabPanel('Maps!',
sidebarLayout(
sidebarPanel(width = 4,
sliderInput('slider',
label = 'Choose the Number of Colors',
min = 1,
max = 9,
value = 4),
selectInput('select',
label = 'Select a Column',
choices = colnames(map_data)[-1],
selected = colnames(map_data)[4])),
mainPanel(plotOutput('mapplot')))),
tabPanel('Map Data',
mainPanel(width = 12,
DT::dataTableOutput('mapdata'))))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.