【发布时间】:2020-12-03 03:12:28
【问题描述】:
我目前正在设计一个带有 shinydashboard 包的 Shiny App。
我正在使用tabsetPanel 布局,我无法更改每个tabPanel 的宽度,以便绘图适合整个窗口宽度。 width = 参数中的值似乎对其没有影响。
我已经尝试了问题中给出的所有解决方案:Shiny: How to adjust the width of the tabsetPanel?,但这些都不适合我。
这是我的代码:
library(shiny)
library(shinydashboard)
header<-dashboardHeader(title="Shiny App")
sidebar<-dashboardSidebar()
body<-dashboardBody(
fluidRow(
mainPanel(
tabsetPanel(
tabPanel("Panel1",
box(plotOutput("plot"),height=420,width = 1400)
)
)
)
)
)
ui<-dashboardPage(header,sidebar,body)
server<-function(input,output) {
output$plot<-renderPlot({plot(1)})
}
shinyApp(ui,server)
无论width 的值是多少,我都有tabPanel 的大小。我不知道如何更改它。
你能帮帮我吗?谢谢!
【问题讨论】:
标签: css r plot shiny shinydashboard