R 增加渲染打印的显示区域

R 增加渲染打印的显示区域,r,shiny,R,Shiny,我在主面板中渲染了一个绘图,但Shiny使用的垂直可用空间不足50% 所以我认为在renderPlot中添加height=100可能是明智的。显然,这将增加渲染打印的高度,但不会增加显示区域/iframe 我如何影响Shiny使用多少空间(垂直)来显示渲染的绘图 下面是一些代码摘录,以说明技术上下文 从UI代码: mainPanel( tabsetPanel( tabPanel("line plot", plotOutput("line_plot")), [...] )

我在主面板中渲染了一个绘图,但Shiny使用的垂直可用空间不足50%

所以我认为在renderPlot中添加height=100可能是明智的。显然,这将增加渲染打印的高度,但不会增加显示区域/iframe

我如何影响Shiny使用多少空间(垂直)来显示渲染的绘图

下面是一些代码摘录,以说明技术上下文

从UI代码:

mainPanel(
  tabsetPanel(
    tabPanel("line plot", plotOutput("line_plot")),
    [...]
  )
)
从服务器代码:

output$line_plot <- renderPlot({
  [...]
  gg <- ggplot([...]) + geom_line() 
  print(gg)
}, height=1000)
output$line_plot
#修改负责类的样式
大显示器
# modify styling for responsible class
largerDisplay <- HTML('.shiny-plot-output {min-height:800px; max-height:800px}</style>')

shinyUI(pageWithSidebar(
  headerPanel("R Big Pivot"),
  sidebarPanel(
    [...]
  ),

  mainPanel(

  # include the styling
  tags$head(largerDisplay),
    tabsetPanel(
      tabPanel("line plot", plotOutput("line_plot")),
      [...]
    )
  )
))