reactiveGeneSetDb.Rd
This can be instantiated from a "static" or "reactive" GeneSetDb object. It allows users to customize which genesets are active by:
reactiveGeneSetDb(
input,
output,
session,
gdb,
min.gs.size = 2L,
max.gs.size = Inf,
default_collections = NULL,
...
)
reactiveGeneSetDbUI(id, min = 2, max = 100L, ...)
shiny module bits
A static or reactive GeneSetDb object
the default minimum and maximum geneset size set in the UI when `gdb` is first loaded or changes (when reactive)
a character vector of collections that are by default selected for use
pass through args
shiny module namespace
ranges for the min/max geneset slider
A list of reactive elements wired to the input `gdb`:
a `reactive(gdb)`
a `reacvtive(geneSets(gdb))`
reactives that indicate current selection of minimum and maximum gene set sizes to be used in `sparrow::conform(gdb, ...)`
a `shiny::reactiveList` that contains the state of this module
the shiny namespace for this module
1. Filtering out entire collections; and 2. Filtering genesets based on min and max (gene) size.
reactiveGeneSetDbUI
: the UI for the module
sres <- sparrow::exampleSparrowResult()
gdb <- sparrow::geneSetDb(sres)
app <- shiny::shinyApp(
ui = shiny::shinyUI(shiny::fluidPage(
exampleUISetup(),
title = "Configure GeneSetDb",
reactiveGeneSetDbUI("mod"))),
server = function(input, output, session) {
shiny::callModule(reactiveGeneSetDb, "mod", gdb)
})
if (interactive()) {
shiny::runApp(app)
}