Update content on server only after I click action button in Shiny

前端 未结 1 872
心在旅途
心在旅途 2020-12-19 09:40

I\'m having problems with reactive output in shiny server in R.

What I want to do is create a plotly plot that uses values calculated based on input.

The out

相关标签:
1条回答
  • 2020-12-19 10:30

    submitButton is just made for this.


    If you want to use actionButton instead, simply use isolate to avoid refresh based on value changes, and add the input$Buttonin the code like:

    output$Minimal_Example <- renderPrint({
      input$Button
      Age <- isolate(input$Age)
      Sex <- isolate(input$ChosenSex)
      c(Age, Sex)
    }) 
    
    0 讨论(0)
提交回复
热议问题