Title: | Volcano Plot for Clinical Trial Adverse Events |
---|---|
Description: | Interactive adverse event (AE) volcano plot for monitoring clinical trial safety. This tool allows users to view the overall distribution of AEs in a clinical trial using standard (e.g. MedDRA preferred term) or custom (e.g. Gender) categories using a volcano plot similar to proposal by Zink et al. (2013) <doi:10.1177/1740774513485311>. This tool provides a stand-along shiny application and flexible shiny modules allowing this tool to be used as a part of more robust safety monitoring framework like the Shiny app from the 'safetyGraphics' R package. |
Authors: | Jeremy Wildfire [cre, aut], Becca Krouse [aut], Natalia Andriychuk [aut], Anh Tran [aut], Isaac Zhao [aut] |
Maintainer: | Jeremy Wildfire <[email protected]> |
License: | MIT + file LICENSE |
Version: | 1.0.0 |
Built: | 2025-02-23 03:47:59 UTC |
Source: | https://github.com/cran/volcanoPlot |
Compares reference and comparison groups to calculate group-wise metrics and p-values for use in AE volcano plot.
getStats(dfAE, dfDemog, settings, stat = "Risk Ratio")
getStats(dfAE, dfDemog, settings, stat = "Risk Ratio")
dfAE |
Adverse events dataset structured as 1 record per adverse event per subject |
dfDemog |
Subject-level dataset |
settings |
Named list of settings (see examples below for standard list) |
stat |
Statistic to calculate for AE plot. Options are risk ratio ("RR" or "Risk Ratio"), risk difference ("RD" or "Risk Difference"). Defaults to "Risk Ratio". |
a data frame of group-wise statistics for use in the volcano plot
settings<-list( stratification_col="AEBODSYS", group_col="ARM", reference_group="Placebo", comparison_group="Xanomeline High Dose", id_col="USUBJID" ) getStats(dfAE=safetyData::adam_adae, dfDemog = safetyData::adam_adsl, settings)
settings<-list( stratification_col="AEBODSYS", group_col="ARM", reference_group="Placebo", comparison_group="Xanomeline High Dose", id_col="USUBJID" ) getStats(dfAE=safetyData::adam_adae, dfDemog = safetyData::adam_adsl, settings)
Modularized server for AE volcano plot.
volcano_server(input, output, session, params)
volcano_server(input, output, session, params)
input |
module input |
output |
module output |
session |
module session |
params |
parameters object with 'data' and 'settings' options. |
returns shiny module Server function
Modularized user interface for AE Volcano plot
volcano_ui(id)
volcano_ui(id)
id |
module id |
returns shiny module UI
Initializes stand-alone volcano plot shiny application.
volcanoApp( dfAE = safetyData::adam_adae, dfDemog = safetyData::adam_adsl, settings = NULL, runNow = TRUE )
volcanoApp( dfAE = safetyData::adam_adae, dfDemog = safetyData::adam_adsl, settings = NULL, runNow = TRUE )
dfAE |
AE Data |
dfDemog |
demog data |
settings |
safetyGraphics settings |
runNow |
run app immediately? |
Initializes Shiny app. No return value.
Creates a paneled volcano plot showing the distribution of Adverse events. Options to highlight selected events and customize options are provided.
volcanoPlot(data, highlights = c(), ...)
volcanoPlot(data, highlights = c(), ...)
data |
A data frame from getStats() |
highlights |
A list providing a column and values to be highlighted in the chart |
... |
Extra options to change the look of the plot. 'fillcol = c('sienna2', 'skyblue2', 'grey')': fill colors; 'pcutoff = 0.05': p value cutoff; ‘ecutoff = 1': estimate cutoff, 'GroupLabels = c(’Comparison Group', 'Reference Group')': custom group labels. |
a volcano plot created with ggplot
settings<-list( stratification_col="AEBODSYS", group_col="ARM", reference_group="Placebo", comparison_group="Xanomeline High Dose", id_col="USUBJID" ) stats<-getStats(dfAE=safetyData::adam_adae, dfDemog = safetyData::adam_adsl, settings) volcanoPlot(stats)
settings<-list( stratification_col="AEBODSYS", group_col="ARM", reference_group="Placebo", comparison_group="Xanomeline High Dose", id_col="USUBJID" ) stats<-getStats(dfAE=safetyData::adam_adae, dfDemog = safetyData::adam_adsl, settings) volcanoPlot(stats)