Teal Module: Patient Medical History Teal Module
Source:R/tm_t_pp_medical_history.R
tm_t_pp_medical_history.Rd
This teal module produces a patient medical history report using ADaM datasets.
Usage
tm_t_pp_medical_history(
label,
dataname = "ADMH",
parentname = "ADSL",
patient_col = "USUBJID",
mhterm = NULL,
mhbodsys = NULL,
mhdistat = NULL,
pre_output = NULL,
post_output = NULL
)
Arguments
- label
(
character
)
menu item label of the module in the teal app.- dataname
(
character
)
analysis data used in teal module.- parentname
(
character
)
parent analysis data used in teal module, usually this refers toADSL
.- patient_col
(
character
)
patient ID column to be used.- mhterm
(
teal.transform::choices_selected()
orteal.transform::data_extract_spec()
)MHTERM
column of the ADMH dataset.- mhbodsys
(
teal.transform::choices_selected()
orteal.transform::data_extract_spec()
)MHBODSYS
column of the ADMH dataset.- mhdistat
(
teal.transform::choices_selected()
orteal.transform::data_extract_spec()
)MHDISTAT
column of the ADMH dataset.- pre_output
optional, (
shiny.tag
)
with text placed before the output to put the output into context. For example a title.- post_output
optional, (
shiny.tag
)
with text placed after the output to put the output into context. For example theshiny::helpText()
elements are useful.
Examples
adsl <- tmc_ex_adsl
admh <- tmc_ex_admh
app <- init(
data = cdisc_data(
cdisc_dataset("ADSL", adsl),
cdisc_dataset("ADMH", admh)
),
modules = modules(
tm_t_pp_medical_history(
label = "Medical History",
dataname = "ADMH",
parentname = "ADSL",
patient_col = "USUBJID",
mhterm = choices_selected(
choices = variable_choices(admh, c("MHTERM")),
selected = "MHTERM"
),
mhbodsys = choices_selected(
choices = variable_choices(admh, "MHBODSYS"),
selected = "MHBODSYS"
),
mhdistat = choices_selected(
choices = variable_choices(admh, "MHDISTAT"),
selected = "MHDISTAT"
)
)
)
)
#> [INFO] 2023-05-31 23:41:47.4076 pid:3043 token:[] teal.modules.clinical Initializing tm_t_pp_medical_history
if (interactive()) {
shinyApp(app$ui, app$server)
}