ggdownload_popup: Download ggplots with a modal window

Description Usage Arguments Examples

Description

this module invokes a modal window, where parameters for the function ggsave() can be specified'

Usage

1
2
3
ggdownload_popup_ui(id, label = "download...")

ggdownload_popup_server(input, output, session, plotObj)

Arguments

id

module identifier

label

label of the button

input, output, session

Standard module parameters

plotObj

A reactive ggplot object

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
## Not run: 
shinyApp(
  ui = fluidPage(
    ggdownload_popup_ui("gg_popup")
  ),
  server = function(input, output, session) {
    plot <- reactive({
      library(ggplot2)
      ggplot(mtcars) + aes(wt, mpg) + geom_point()
    })
    callModule(ggdownload_popup_server, "gg_popup", plot)
  }
)

## End(Not run)

statistikat/codeModules documentation built on Feb. 17, 2021, 11:42 a.m.