这让我很痛苦。
我想 simlpy 有一个带有日期的滑块输入(最好按月步进)并因此更改一个简单的 ggplot_bar 。尽管我可以显示所有内容,但似乎对滑块的更改没有响应:
这是我的代码:
library(shiny)
# Define UI for application that draws a histogram
shinyUI(fluidPage(
# Application title
titlePanel("St Thomas' Physiology Data Console"),
# Sidebar with a slider input for the number of bins
sidebarLayout(
sidebarPanel(
sliderInput("DatesMerge",
"Dates:",
min = as.Date("2006-01-01","%Y-%m-%d"),
max = as.Date("2016-12-01","%Y-%m-%d"),
value=as.Date("2016-12-01"),timeFormat="%Y-%m-%d")
),
# Show a plot of the generated distribution
mainPanel(
tabsetPanel(
tabPanel("Breath Tests",plotOutput("distPlotLactul")),
)
)
))
Run Code Online (Sandbox Code Playgroud)
library(shiny)
source("S:\\Usage.R")
# Define server logic required to draw a histogram
shinyServer(function(input, output) { …Run Code Online (Sandbox Code Playgroud)