title: R Shiny App for Linear Regression, Issue with Render Functions
body: <p>When I run my code, I am not getting any errors and my app is staying live (not turning to a grey screen because of an error in code). However, I am not getting any output on the left side of my screen. I am assuming that I have some type of syntax error somewhere, but I can't quite figure it out. Here is my code, it should be easy to run on your own R Studio. </p>
  
  <p>Here is my UI:</p>
  
  <pre><code>shinyUI(fluidPage(
    titlePanel("Linear Regression"),
  
    sidebarLayout(position = "right",
      mainPanel(h2("Your Model"), dataTableOutput("table")),
      sidebarPanel(h2("Your Data"),
  
        fileInput("mydata", label = h4("Please upload the .xls, .txt, or.csv file you would like included in the analysis. Please use column names in your dataset.")),
  
        textInput("response", label=h4 ("What is the column name of your response variable?")),
  
        textInput("explan1", label=h4 ("What is the column name of your explanitory variable?")),
  
        actionButton("analysis", "Analyze!"),
        verbatimTextOutput("modelSummary"), 
        plotOutput("plot")
  
        )
      )
    )
  )
  </code></pre>
  
  <p>And here is my Server:</p>
  
  <pre><code>shinyServer({
    function(input, output) ({
      observeEvent(input$analysis, {
       reactive({
          dat &lt;- file.path(input$mydata)
  
          response=input$response
          explan1=input$explan1
  
          plot(input$response~input$explan1, data=dat)
  
          mean.response&lt;-mean(dat$response,na.rm=T)
  
          abline(h=mean.Premium)
  
          model=lm(response~explan1, data = dat)
  
          output$plot &lt;- renderPlot({
            plot(input$response~input$explan1, data= dat)
            abline(model,col="red")
          })
  
          output$modelSummary &lt;- renderPrint({
            summary(model)
          })
        })   
      })
    })
  })
  </code></pre>
  
  <p>For renderText I am trying to get it to output the whole summary.
  Thanks!</p>