Closed
Description
It is possible to pass width='100%'
into plotlyOutput
so that the plot takes all of the horizontal space. The help text also suggests height='100%'
as an example, but this always results in a 400px static height.
However, plotly plots are usually 100% height and width when the graphs are stand-alone HTML, so I'm not sure why it wouldn't be possible to have 100% height within a Shiny app.
library(shiny)
ui = shinyUI(fluidPage(plotly::plotlyOutput('plot', width='100%', height='100%')))
server = shinyServer(function(input, output, session) {
output$plot = plotly::renderPlotly({ plotly::plot_ly(data=airquality, x=~Ozone, y=~Solar.R) })
})
runApp(list(ui=ui, server=server))
Output screenshot:
Metadata
Metadata
Assignees
Labels
No labels