title: Plots in DT table
body: <p>In the below application, the column e has some plots. But when you open the application it does not show. But when you click on any of the column headers, you see the plots in column e. Why is that so? Can we not have by default?</p>
  <pre><code>library(shiny)
  library(DT)
  library(glue)
  library(dplyr)
  
  asd1 &lt;- data.frame(a = c(3,4,5,6), b = c(&quot;A&quot;,&quot;B&quot;,&quot;C&quot;,&quot;D&quot;))
  asd_fun &lt;- function(x){as.vector(asd1$b)}
  
  ui &lt;- fluidPage(
    selectInput(&quot;do&quot;, &quot;select&quot;, choices = sapply(asd1$a, asd_fun)),
    selectInput(&quot;do1&quot;, &quot;select1&quot;, choices = c(&quot;a&quot; = 50,&quot;b&quot; = 100)),
    dataTableOutput(&quot;graph1&quot;)
  )
  
  server &lt;- function(input, output, session) {
     
    # a1 &lt;- 3
    
   
    
      output$graph1 &lt;- renderDataTable({
        df_1 &lt;- data.frame(a = c(50,100,150), b= c(860,1600,300), c = c(1140, 1700, 700),
                           d= c(960,1700,400), x = c(1130, 1100, 800),
                           y= c(160,700,300), z = c(130, 100, 300))
        
        df1 &lt;-  df_1 %&gt;% filter(a %in% input$do1) %&gt;% mutate(bc = paste0(b, &quot;,&quot;, c), dx = paste0(d, &quot;,&quot;, x), yz = paste0(y, &quot;,&quot;, z), e =  c(glue::glue(HTML('
  &lt;html&gt;
  &lt;script src=&quot;https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.5.0/Chart.min.js&quot;&gt;&lt;/script&gt;
  &lt;body&gt;
  &lt;canvas id=&quot;myChart{a}&quot; style=&quot;width:100%;max-width:600px&quot;&gt;&lt;/canvas&gt;
  
  &lt;script&gt;
  var xValues = [1,3];
  
  new Chart(&quot;myChart{a}&quot;, {{
    type: &quot;line&quot;,
    data: {{
      labels: xValues,
      datasets: [{{ 
        data: [{bc}],
        borderColor: &quot;red&quot;,
        fill: false
      }}, {{ 
        data: [{dx}],
        borderColor: &quot;green&quot;,
        fill: false
      }}, {{ 
        data: [{yz}],
        borderColor: &quot;blue&quot;,
        fill: false
      }}]
    }},
    options: {{
      legend: {{display: false}}
    }}
  }});
  &lt;/script&gt;
  '))))
        
        datatable(df1, escape = F,rownames = F,selection = 'none', options = list(autowidth = FALSE))
      
    })
  }
  
  shinyApp(ui, server)
  </code></pre>
  <p>Why is that so? Can we not have by default?</p>