title: Cannot display plot in Rshiny
body: <p>I have a shiny app and what I am trying to do is to print the header or full data frame in one tab, summary in another tab and finally a plot in the third tab. For some reason, I was able to generate the table and summary in the first two tabs but not the plot. I don't know what I am doing wrong. </p>
  
  <p>Here is my <code>ui.R</code> script</p>
  
  <pre><code>library(shiny)
  library(shinyFiles)
  
  shinyUI(pageWithSidebar(
    headerPanel(
      'Selections with shinyFiles',
      'shinyFiles example'
    ),
    sidebarPanel(
      tags$h3('Select your file'),
  
      # Shiny button   
      shinyFilesButton(id = 'file', label = 'File select', title = 'Please select a file', multiple = FALSE),
  
      tags$h3('Select your options for table'),
  
      # Horizontal line ----
      br(),
  
      # Input: Checkbox if file has header ----
      checkboxInput("header", "Header", TRUE),
  
      # Input: Select separator ----
      radioButtons("sep", "Separator",
                   choices = c(Comma = ",",
                               Semicolon = ";",
                               Tab = "\t"),
                   selected = ","),
  
      # Input: Select quotes ----
      radioButtons("quote", "Quote",
                   choices = c(None = "",
                               "Double Quote" = '"',
                               "Single Quote" = "'"),
                   selected = '"'),
  
      # Horizontal line ----
      tags$hr(),
  
      # Input: Select number of rows to display ----
      radioButtons("disp", "Display",
                   choices = c(Head = "head",
                               All = "all"),
                   selected = "head"),
  
      tags$h3('Select your options for plotting'),
  
      br(),
  
      # Input: 
      radioButtons("sho", "Show",
                   choices = c(Yes = "yes",
                               No = "no"),
                   selected = "yes")
      ),
    mainPanel(
      tabsetPanel(type = "tabs",
                  tabPanel("Table", dataTableOutput("contents")),
                  tabPanel("Summary", verbatimTextOutput("summary")),
                  tabPanel("Plot", plotOutput("plt"))
  
    )
    ))
  )
  </code></pre>
  
  <p>And here is my <code>server.R</code> script</p>
  
  <pre><code>library(shiny)
  library(shinyFiles)
  
  shinyServer(function(input, output, session) {
    shinyFileChoose(input, 'file', roots=c(wd='/Users/upendra_35/Documents/CyVerse/Images_apps/DE/VICE/'), filetypes=c('', 'csv'))
    shinySaveButton("save", "Save file", "Save file as ...", filetype=c('', "csv"))
    output$contents &lt;- renderDataTable({
      inFile &lt;- parseFilePaths(roots=c(wd='/Users/upendra_35/Documents/CyVerse/Images_apps/DE/VICE/'), input$file)
      if( NROW(inFile)) {
        df &lt;- read.csv(as.character(inFile$datapath),
                       header = input$header,
                       sep = input$sep,
                       quote = input$quote)
        if(input$disp == "head") {
          return(head(df))
        }
        else {
          return(df)
        }
      }
    })
  
  
    output$summary &lt;- renderPrint({
      inFile &lt;- parseFilePaths(roots=c(wd='/Users/upendra_35/Documents/CyVerse/Images_apps/DE/VICE/'), input$file)
      if( NROW(inFile)) {
        df &lt;- read.csv(as.character(inFile$datapath),
                       header = input$header,
                       sep = input$sep,
                       quote = input$quote)
  
        summary(df)
      }
    })
  
    output$plt &lt;- renderPlot({
      inFile &lt;- parseFilePaths(roots=c(wd='/Users/upendra_35/Documents/CyVerse/Images_apps/DE/VICE/'), input$file)
      if( NROW(inFile)) {
        df &lt;- read.csv(as.character(inFile$datapath),
                       header = input$header,
                       sep = input$sep,
                       quote = input$quote)
        if(input$sho == "yes") {
          manh &lt;- manhattanr(df, chr = "chrom", bp = "pos", p = "P", snp = "marker")
          manhattanly(manh, col=c("#D2691E","#800080","#6495ED","#9ACD32"), point_size=7, showlegend = FALSE, 
                      xlab = "Chromosome", ylab = "-log10(p)", suggestiveline_color = "blue", suggestiveline_width = 2, 
                      genomewideline =FALSE, title = "")
        }
        else {
          print("No plot")
        }
  
      }
    })
  
  })
  </code></pre>
  
  <p>The code for the plot definitely works when I run it manually in the R console.</p>