PlotStatic Module Class
PlotStatic.Rd
Static plot Module that handles static plots like from the base::plot()
function or ggplot2
objects.
Super classes
DarwinShinyModules::ShinyModule
-> DarwinShinyModules::Plot
-> PlotStatic
Examples
library(DarwinShinyModules)
library(ggplot2)
staticFun <- function(data) {
ggplot(data = data, mapping = aes(x = Sepal.Length, y = Sepal.Width, color = Species)) +
geom_point() +
theme_bw()
}
staticModule <- PlotStatic$new(fun = staticFun, args = list(data = iris))
if (interactive()) {
preview(staticModule)
}