Provides module for creating and editing subpopulations.

Format

R6 class

Input

datalist

A list of data sets. Can be tibbles, data frames, etc. Expects them to have a common ID field (default is USUBJID)

options

The options for the module of type reactiveValues with values

subjectDs

If one of the data sets in datalist contains subject level data then provide it here. Default: ADSL

idvar

ID field that is common across all datasets in datalist. Default USUBJID

Output

populations

List of PopulationFilter S3 objects.

See also

Super class

tidymodules::TidyModule -> SubpopulationManager

Methods

Public methods

Inherited methods

Method new()

Usage

SubpopulationManager$new(...)


Method ui()

Usage

SubpopulationManager$ui()


Method server()

Usage

SubpopulationManager$server(
  input,
  output,
  session,
  datalist = NULL,
  options = NULL
)


Method clone()

The objects of this class are cloneable with this method.

Usage

SubpopulationManager$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.

Examples

if (FALSE) { library(tidymodules) library(subpat) library(bs4Dash) subpopmod <- SubpopulationManager$new(id = "subpopmodule") ui <- tagList( shinyjs::useShinyjs(), bs4DashPage( sidebar = bs4DashSidebar(disable = TRUE), body = bs4DashBody( subpopmod$ui() ) ) ) # Define server logic server <- function(input, output) { datalist <- reactive({ example_datasets }) opts <- reactiveValues( subjectDs = "ADSL", idvar = "USUBJID" ) subpopmod$callModule() observe({ # Pass the data into the module datalist %>1% subpopmod # Add the options to the subpopulation manager opts %>2% subpopmod }) } # Run the application shinyApp(ui = ui, server = server) }