Skip to contents

Creates nice cohort method plots

Usage

plotCmEstimates(
  cmData,
  cmMeta = NULL,
  targetName,
  comparatorName,
  selectedAnalysisId
)

Arguments

cmData

The cohort method data

cmMeta

(optional) The cohort method evidence synthesis data

targetName

A friendly name for the target cohort

comparatorName

A friendly name for the comparator cohort

selectedAnalysisId

The analysis ID of interest to plot

Value

Returns a ggplot with the estimates

Details

Input the cohort method data

Examples

conDet <- getExampleConnectionDetails()

connectionHandler <- ResultModelManager::ConnectionHandler$new(conDet)
#> Connecting using SQLite driver

cmEst <- getCMEstimation(
  connectionHandler = connectionHandler, 
  schema = 'main',
  targetIds = 1,
  outcomeIds = 3
)
plotCmEstimates(
  cmData = cmEst, 
  cmMeta = NULL, 
  targetName = 'target', 
  comparatorName = 'comp', 
  selectedAnalysisId = 1
)
#> NULL