Shiny 闪亮的仪表板多个图表-重叠

Shiny 闪亮的仪表板多个图表-重叠,shiny,dashboard,rcharts,Shiny,Dashboard,Rcharts,我正在为我的应用程序使用闪亮的仪表板软件包。 当试图在同一页上显示两个绘图(每个绘图在一个框中)时,它们是重叠的。 还尝试对每个绘图使用fluidRow,但似乎两个绘图都连接到同一个框(并且重叠) 这是我的代码: mainPanel( fluidRow( box(showOutput("MeasuresPlot","morris"),width=6,title="Graph"), box(showOutput("ImportPlot","morris"),width=

我正在为我的应用程序使用闪亮的仪表板软件包。 当试图在同一页上显示两个绘图(每个绘图在一个框中)时,它们是重叠的。 还尝试对每个绘图使用fluidRow,但似乎两个绘图都连接到同一个框(并且重叠)

这是我的代码:

 mainPanel(
  fluidRow( 
     box(showOutput("MeasuresPlot","morris"),width=6,title="Graph"),
     box(showOutput("ImportPlot","morris"),width=6,title="Graph2")
   )      
  )

在流体行中,您可以使用如下列:

library(shiny)
library(shinydashboard)


ui <-dashboardPage(
    dashboardHeader(),
    dashboardSidebar(),
    dashboardBody(
      fluidRow(
        column(6,box(plotOutput("plt1"),width=12,title="Graph",background ="green") ),
        column(6,box(plotOutput("plt2"),width=12,title="Graph2",background="yellow") )
      ),
      fluidRow( actionButton("plot","plot") )
    )
)

server <- shinyServer(function(input, output, session) {
  observeEvent(input$plot,{
    output$plt1 <- renderPlot({plot(runif(100),runif(100))})
    output$plt2 <- renderPlot({plot(runif(100),runif(100))})
  })
})

shinyApp(ui = ui, server = server)
库(闪亮)
图书馆(shinydashboard)
用户界面