Ranon Kahn Ranon Kahn -4 years ago 243
R Question

R Shiny layout - side by side chart and/or table within a tab

I wish to plot a curve and the data table side by side within a tab in R Shiny as shown in the images below. I am aware from the R Shiny layout documentation that the side by side plot and table layout is possible when not using tabs. But I would like to have the side by side layout within a tab if possible. Any suggestions?

As is
enter image description here

Wish to be like this

enter image description here

Answer Source

Basically you can do it about the same way you would do it without tabs - within a tab you make different columns for your outputs. You can divide up the contents of each tab however you wish.

    tabPanel(h4("My Tab"),
         h3("My Plot"),
         plotOutput("My Plot")
         h3("My Table"),
     tabPanel(h4("Next Tab"),
       ..... etc   
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download