Is it possible to have the product from two inputs as a default value for another input?
Even, more complex, is it possible to include an if cycle in the computation?
Example:
library(shiny)
ui <- fluidPage(
numericInput("factor","Factor:")
numericInput("delta","Delta:"),
numericInput("size","Size:"),
numericInput("result","result:",value = input$delta*input$size)
)
Advanced:
I would like to have input$delta*input$size
multiplied for input$factor
if input$factor
is different than 100.
I tried to pass the value in the server by connecting it to an output and then having the latest as input but it did not work (I would say obviously).
Any help?