显示闪亮应用程序的数据表

时间:2021-05-06 18:49:22

标签: r shiny shinyapps

在尝试创建反应表后,我得到了一个空白屏幕。这是我的代码

PitcherList <- unique(master2$mlb_name)
ui <- fluidPage(
  titlePanel("Position of Home Runs"),
   sidebarLayout(
      sidebarPanel(
        selectInput("Selectpitcher", h3("Select box"),
                choices = PitcherList, selected = "Aaron Nola")
  ),
    mainPanel(
       h2("Player Table"),
       DT::dataTableOutput("pitchTypes"))
   ))

server <- function(input, output) {
   SelectedTypeReactive<-reactive({
    pitch_type_chart %>% filter(mlb_name == input$Selectpitcher)})
   output$PitchTypes<-DT::renderDT({SelectedTypeReactive()})
  
}
shinyApp(ui = ui, server = server)```
Why is the table not showing up?

0 个答案:

没有答案
相关问题