title: construct an small app using shiny, after i code a loop it keeps giving me error
body: <p>construct an small app using shiny, after i code a loop it keeps giving me error</p>
  
  <p>Why am I getting this error"evaluation nested too deeply: infinite recursion / options(expressions=)?"</p>
  
  <pre><code>library(shiny)
  ui&lt;-fluidPage(
    numericInput(inputId = "S0",label = "price at time 0",value = 20),
    numericInput(inputId = "k",label = "exercise price",value = 20),
    numericInput(inputId = "N",label = "steps",value = 50),
    numericInput(inputId = "r",label = "riskfree rate",value = 0.03),
    numericInput(inputId = "t",label = "time to exercise data",value = 1),
     plotOutput(outputId = "v")
  )
  
  server&lt;-function(input,output)
  {
  
    ve&lt;-reactive({vector(mode="numeric",length=input$N+1)})
    ve&lt;-reactive({rep(input$N,9)})
  
  
    for(i in 1:10)   
    {
      ve&lt;-reactive({c(ve(),i)})
    }
  
   output$v&lt;-renderPlot({plot(ve())})
  
  }
  
  
  shinyApp(ui=ui,server=server)
  </code></pre>
  
  <p>it seems that something wrong with the for() sentence</p>