Reputation: 872
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?
Upvotes: 0
Views: 2312
Reputation: 12684
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.
tabsetPanel(
tabPanel(h4("My Tab"),
column(6,
h3("My Plot"),
plotOutput("My Plot")
),
column(6,
h3("My Table"),
dataTableOutput("MyTable")
)
),
tabPanel(h4("Next Tab"),
..... etc
Upvotes: 1