服务器输出r闪亮显示尝试应用非功能错误

时间:2019-03-26 05:35:03

标签: r dashboard shinydashboard

我创建了一个闪亮的应用程序,如下所示

 library(shiny)
 library(shinydashboard)
 library(shinydashboardPlus)
 ui <- dashboardPage(
 dashboardHeader(title = "Visualization tool", titleWidth = "250"),
 dashboardSidebar(width = '250', fluidRow(
 div(numericInput(inputId = "ID", label = "ID1", value = 0, min = 0, max = 
 1000)))),
 dashboardBody(
 fluidRow(column(7,textOutput(outputId = "Table2")))))
 server <- function(input, output) {   
 output$Table2=renderText({
 value=input$ID()
 return(value)
 })}


 shinyApp(ui, server)

该应用程序在边栏中有一个输入框,生成的数字应显示在主面板上。 Hoewevr,出现以下错误

 attempt to apply non-function

我找不到问题。请求某人检查并提出解决方案

1 个答案:

答案 0 :(得分:0)

我发现了错误

   server <- function(input, output) {   
   output$Table2=renderText({
   value=input$ID
   return(value)
    })}