Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 21 additions & 3 deletions R/prepare_ae_forestly.R
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,23 @@
#' Prepare datasets for interactive forest plot
#'
#' @inheritParams metalite.ae::prepare_ae_specific
#' @param meta A metadata object created by metalite.
#' @param population A character value of population term name.
#' The term name is used as key to link information.
#' @param observation A character value of observation term name.
#' The term name is used as key to link information.
#' @param parameter A character value of parameter term name.
#' The term name is used as key to link information.
#' @param components A character vector of components name, default value is `"par"`.
#' @param reference_group An integer to indicate reference group.
#' Default is 2 if there are 2 groups, otherwise, the default is 1.
#' @param ae_listing_display A vector of name of variables used to display
#' on AE listing table.
#' @param ae_listing_unique A logical value to display only unique records
#' on AE listing table.
#'
#' @param bisection A numeric value. A control parameter for the bisection
#' method used to calculate confidence the lower and upper confidence
#' interval bounds for the risk. The default value is `1e2`.
#' @return An `outdata` object.
#'
#' @export
Expand All @@ -47,7 +59,10 @@ prepare_ae_forestly <- function(
"USUBJID", "SITEID", "SEX", "RACE", "AGE", "ASTDY", "AESER",
"AEREL", "AEACN", "AEOUT", "ADURN", "ADURU"
),
ae_listing_unique = FALSE) {
ae_listing_unique = FALSE,
bisection = 1e2,
...
) {
if (is.null(population)) {
if (length(meta$population) == 1) {
population <- meta$population[[1]]$name
Expand Down Expand Up @@ -103,7 +118,10 @@ prepare_ae_forestly <- function(
components = components,
reference_group = reference_group
) |>
metalite.ae::extend_ae_specific_inference() |>
metalite.ae::extend_ae_specific_inference(
bisection = bisection,
...
) |>
collect_ae_listing(display = ae_listing_display) |>
format_ae_listing(display_unique_records = ae_listing_unique)
})
Expand Down
10 changes: 8 additions & 2 deletions man/prepare_ae_forestly.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading