Houses the results of a TreatmentPatterns analysis. Each field corresponds
to a file. Plotting methods are provided.
Active bindings
attrition(
data.frame)metadata(
data.frame)treatment_pathways(
data.frame)summary_event_duration(
data.frame)counts_age(
data.frame)counts_sex(
data.frame)counts_year(
data.frame)cdm_source_info(
data.frame)analyses(
data.frame)arguments(
list)
Methods
Method new()
Initializer method
Usage
TreatmentPatternsResults$new(
attrition = NULL,
metadata = NULL,
treatmentPathways = NULL,
summaryEventDuration = NULL,
countsAge = NULL,
countsSex = NULL,
countsYear = NULL,
cdmSourceInfo = NULL,
analyses = NULL,
arguments = NULL,
filePath = NULL
)Arguments
attrition(
data.frame) attrition result.metadata(
data.frame)) metadata result.treatmentPathways(
data.frame)) treatmentPathways result.summaryEventDuration(
data.frame)) summaryEventDuration result.countsAge(
data.frame)) countsAge result.countsSex(
data.frame)) countsSex result.countsYear(
data.frame)) countsYear result.cdmSourceInfo(
data.frame) cdmSourceInfo result.analyses(
data.frame) Analyses result.arguments(
list) Named list of arguments used.filePath(
character) File path to either a directory or zip-file, containing the csv-files.
Method saveAsZip()
Save the results as a zip-file.
Method uploadResultsToDb()
Upload results to a resultsDatabase using ResultModelManager.
Usage
TreatmentPatternsResults$uploadResultsToDb(
connectionDetails,
schema,
prefix = "tp_",
overwrite = TRUE,
purgeSiteDataBeforeUploading = FALSE
)Arguments
connectionDetails(
ConnectionDetails) ConnectionDetails object fromDatabaseConnector.schema(
character(1)) Schema to write tables to.prefix(
character(1):"tp_") Table prefix.overwrite(
logical(1):TRUE) Should tables be overwritten?purgeSiteDataBeforeUploading(
logical:FALSE) Should site data be purged before uploading?
Method load()
Load data from files.
Method plotSunburst()
Wrapper for TreatmentPatterns::createSunburstPlot(), but with data filtering step.
Usage
TreatmentPatternsResults$plotSunburst(
age = "all",
sex = "all",
indexYear = "all",
nonePaths = FALSE,
...
)Arguments
age(
character(1)) Age group.sex(
character(1)) Sex group.indexYear(
character(1)) Index year group.nonePaths(
logical(1)) ShouldNonepaths be included?...Parameters for
TreatmentPatterns::createSunburstPlot()
Method plotSankey()
Wrapper for TreatmentPatterns::createSankeyDiagram(), but with data filtering step.
Usage
TreatmentPatternsResults$plotSankey(
age = "all",
sex = "all",
indexYear = "all",
nonePaths = FALSE,
...
)Arguments
age(
character(1)) Age group.sex(
character(1)) Sex group.indexYear(
character(1)) Index year group.nonePaths(
logical(1)) ShouldNonepaths be included?...Parameters for
TreatmentPatterns::createSankeyDiagram()
Method plotEventDuration()
Wrapper for TreatmentPatterns::plotEventDuration().
Arguments
...Parameters for
TreatmentPatterns::plotEventDuration()