UI & server for module to create MA plot
Examples
if (FALSE) { # interactive()
library(shiny)
library(DESeq2)
# Create reactive values to simulate app state
oobj <- make_example_carnation_object()
obj <- reactiveValues(
dds = oobj$dds,
rld = oobj$rld,
res = oobj$res,
all_dds = oobj$all_dds,
all_rld = oobj$all_rld,
dds_mapping = oobj$dds_mapping
)
# Set up coldata structure that the module expects
coldata <- reactiveValues(
curr = list(
all_samples = colData(oobj$dds$main),
main = colData(oobj$dds$main)
)
)
plot_args <- reactive({
list(
fdr.thres=0.1,
fc.thres=0,
gene.to.plot=c('gene1', 'gene2')
)
})
config <- reactiveVal(get_config())
shinyApp(
ui = fluidPage(
sidebarPanel(maPlotUI('p', 'sidebar')),
mainPanel(maPlotUI('p', 'main'))
),
server = function(input, output, session){
maPlotServer('p', obj, plot_args, config)
}
)
}