run_gsm_app() creates a Shiny app to explore a set of clinical
trial data. The app facilitates exploration of the data by allowing the user
to click to diver deeper into aspects of the data.
run_sample_gsm_app() is a thin wrapper around run_gsm_app(), using the
sample data provided in this package.
Usage
run_gsm_app(
dfAnalyticsInput,
dfBounds,
dfGroups,
dfMetrics,
dfResults,
fnFetchData,
fnCountData = ConstructDataCounter(fnFetchData),
chrDomains = c(AE = "Adverse Events", DATACHG = "Data Changes", DATAENT = "Data Entry",
ENROLL = "Enrollment", LB = "Lab", PD = "Protocol Deviations", QUERY = "Queries",
STUDCOMP = "Study Completion", SUBJ = "Subject Metadata", SDRGCOMP =
"Treatment Completion"),
lPlugins = NULL,
strTitle = ExtractAppTitle(dfGroups),
strFavicon = "angles-up",
strFaviconColor = "#FF5859",
tagListExtra = NULL,
fnServer = NULL
)
run_sample_gsm_app(strFavicon = "angles-up", strFaviconColor = "#FF5859")Arguments
- dfAnalyticsInput
data.frameParticipant-level metric data. This data.frame is created by binding together thelAnalysis"Analysis_Input" list of data.frames output of analysis workflows, with aMetricIDcolumn for the name of each list.- dfBounds
data.frameSet of predicted percentages/rates and upper- and lower-bounds across the full range of sample sizes/total exposure values for reporting. Created withgsm.reporting::MakeBounds().- dfGroups
data.frameGroup-level metadata dictionary. Seevignette("DataReporting", package = "gsm.reporting")for an example.- dfMetrics
data.frameMetric-specific metadata for use in charts and reporting. Created withgsm.reporting::MakeMetric().- dfResults
data.frameA stacked summary of analysis pipeline output. Created withgsm.reporting::BindResults().- fnFetchData
functionA function that takes astrDomainIDargument and optionalstrGroupID,strGroupLevel,strSubjectID, and/ordSnapshotDate, and returns a data.frame. Seesample_fnFetchData()for an example. The returned data.frame contains information about the named domain. If the function throws an error, the error is elevated to the user, so you can use errors to pass requirements through to the user.- fnCountData
functionA function that takes astrDomainIDargument and optionalstrGroupID,strGroupLevel,strSubjectID, and/ordSnapshotDate, and returns an integer count of the number of rows in that filtered domain. By default, this function is constructed usingfnFetchData()andConstructDataCounter().- chrDomains
characterA (named) vector of domains to include in the app. The values of the vector will be used as labels, and the names will be used as IDs. The IDs will be passed tofnFetchData()to fetch data about that domain.- lPlugins
listOptional list of plugins to include in the app.- strTitle
characterA title to display for the overall app.- strFavicon
characterThe name of an icon to use in the browser tab viafavawesome::fav().- strFaviconColor
characterThe hexcode or name of a color to use as the icon fill forfavawesome::fav().- tagListExtra
taglistAn optionalhtmltools::tagList()of additional elements to add to the top of the app.- fnServer
functionA Shiny server function that takes argumentsinput,output, andsession. This function will be called at the start of the main app server function.
Value
An object that represents the app. Printing the object or passing it
to shiny::runApp() runs the app.