Meta-analysis with the HADES EvidenceSynthesis Package
Source:R/Module-EvidenceSynthesis.R
EvidenceSynthesisModule.Rd
Module for for combining causal effect estimates and study diagnostics across multiple data sites in a distributed study. This includes functions for performing meta-analysis and forest plots
Super class
Strategus::StrategusModule
-> EvidenceSynthesisModule
Methods
Method execute()
Executes the EvidenceSynthesis package
Usage
EvidenceSynthesisModule$execute(
connectionDetails,
analysisSpecifications,
executionSettings
)
Arguments
connectionDetails
An object of class
connectionDetails
as created by theDatabaseConnector::createConnectionDetails()
function.analysisSpecifications
An object of type
AnalysisSpecifications
as created bycreateEmptyAnalysisSpecificiations()
.analysisSpecifications
An object of type
AnalysisSpecifications
as created bycreateEmptyAnalysisSpecificiations()
.executionSettings
An object of type
ExecutionSettings
as created bycreateCdmExecutionSettings()
orcreateResultsExecutionSettings()
.
Method createResultsDataModel()
Create the results data model for the module
Usage
EvidenceSynthesisModule$createResultsDataModel(
resultsConnectionDetails,
resultsDatabaseSchema,
tablePrefix = ""
)
Arguments
resultsConnectionDetails
The connection details to the results database which is an object of class
connectionDetails
as created by theDatabaseConnector::createConnectionDetails()
function.resultsConnectionDetails
The connection details to the results database which is an object of class
connectionDetails
as created by theDatabaseConnector::createConnectionDetails()
function.resultsDatabaseSchema
The schema in the results database that holds the results data model.
tablePrefix
A prefix to apply to the database table names (optional).
tablePrefix
A prefix to apply to the database table names (optional).
Method uploadResults()
Upload the results for the module
Usage
EvidenceSynthesisModule$uploadResults(
resultsConnectionDetails,
analysisSpecifications,
resultsDataModelSettings
)
Arguments
resultsConnectionDetails
The connection details to the results database which is an object of class
connectionDetails
as created by theDatabaseConnector::createConnectionDetails()
function.resultsConnectionDetails
The connection details to the results database which is an object of class
connectionDetails
as created by theDatabaseConnector::createConnectionDetails()
function.analysisSpecifications
An object of type
AnalysisSpecifications
as created bycreateEmptyAnalysisSpecificiations()
.analysisSpecifications
An object of type
AnalysisSpecifications
as created bycreateEmptyAnalysisSpecificiations()
.resultsDataModelSettings
The results data model settings as created using [@seealso
createResultsDataModelSettings()
]
Method createEvidenceSynthesisSource()
Usage
EvidenceSynthesisModule$createEvidenceSynthesisSource(
sourceMethod = "CohortMethod",
databaseIds = NULL,
analysisIds = NULL,
likelihoodApproximation = "adaptive grid"
)
Arguments
sourceMethod
The source method generating the estimates to synthesize. Can be "CohortMethod" or "SelfControlledCaseSeries"
databaseIds
The database IDs to include. Use
databaseIds = NULL
to include all database IDs.analysisIds
The source method analysis IDs to include. Use
analysisIds = NULL
to include all analysis IDs.likelihoodApproximation
The type of likelihood approximation. Can be "adaptive grid" or "normal".
Method createRandomEffectsMetaAnalysis()
Usage
EvidenceSynthesisModule$createRandomEffectsMetaAnalysis(
alpha = 0.05,
evidenceSynthesisAnalysisId = 1,
evidenceSynthesisDescription = "Random-effects",
evidenceSynthesisSource = NULL,
controlType = "outcome"
)
Method createFixedEffectsMetaAnalysis()
Usage
EvidenceSynthesisModule$createFixedEffectsMetaAnalysis(
alpha = 0.05,
evidenceSynthesisAnalysisId = 1,
evidenceSynthesisDescription = "Fixed-effects",
evidenceSynthesisSource = NULL,
controlType = "outcome"
)
Method createBayesianMetaAnalysis()
Usage
EvidenceSynthesisModule$createBayesianMetaAnalysis(
chainLength = 1100000,
burnIn = 1e+05,
subSampleFrequency = 100,
priorSd = c(2, 0.5),
alpha = 0.05,
robust = FALSE,
df = 4,
seed = 1,
evidenceSynthesisAnalysisId = 1,
evidenceSynthesisDescription = "Bayesian random-effects",
evidenceSynthesisSource = NULL,
controlType = "outcome"
)
Arguments
chainLength
Number of MCMC iterations.
burnIn
Number of MCMC iterations to consider as burn in.
subSampleFrequency
Subsample frequency for the MCMC.
priorSd
A two-dimensional vector with the standard deviation of the prior for mu and tau, respectively.
alpha
The alpha (expected type I error) used for the credible intervals.
robust
Whether or not to use a t-distribution model; default: FALSE.
df
Degrees of freedom for the t-model, only used if robust is TRUE.
seed
The seed for the random number generator.
evidenceSynthesisAnalysisId
description
evidenceSynthesisDescription
description
evidenceSynthesisSource
description
controlType
description Create EvidenceSynthesis diagnostics thresholds
Method createEsDiagnosticThresholds()
Threshold used to determine if we pass or fail diagnostics.
Usage
EvidenceSynthesisModule$createEsDiagnosticThresholds(
mdrrThreshold = 10,
easeThreshold = 0.25,
i2Threshold = 0.4,
tauThreshold = log(2)
)
Arguments
mdrrThreshold
What is the maximum allowed minimum detectable relative risk (MDRR)?
easeThreshold
What is the maximum allowed expected absolute systematic error (EASE).
i2Threshold
What is the maximum allowed I^2 (measure of between-database heterogeneity in random-effects models)?
tauThreshold
What is the maximum allowed tau (measure of between-database heterogeneity in Bayesian random-effects models)?
Method createModuleSpecifications()
Creates the module Specifications
Usage
EvidenceSynthesisModule$createModuleSpecifications(
evidenceSynthesisAnalysisList,
esDiagnosticThresholds = self$createEsDiagnosticThresholds()
)
Arguments
evidenceSynthesisAnalysisList
A list of objects of type
EvidenceSynthesisAnalysis
as generated by either theEvidenceSynthesisModule$createFixedEffectsMetaAnalysis()
orEvidenceSynthesisModule$createBayesianMetaAnalysis()
function.esDiagnosticThresholds
An object of type
EsDiagnosticThresholds
as generated by theEvidenceSynthesisModule$createEsDiagnosticThresholds()
function.