Skip to contents

Build Status codecov.io CRAN_Status_Badge CRAN_Status_Badge

Introduction

This package contains functions for extracting characterization, estimation and prediction results from the OHDSI result database (see https://ohdsi.github.io/Strategus/results-schema/index.html).

It also contains codes to create useful plots, presentations templates and report templates.

Examples

Download this repository and using RStudio, install the package. Then you can make use of the report generator by running:


# Install OhdsiReportGenerator using remotes}
install.packages('remotes')
remotes::install_github('OHDSI/OhdsiReportGenerator')

# Load the library to start using it
library(OhdsiReportGenerator)

# to run the report generator with a demo set of results
conDet <- OhdsiReportGenerator:::getExampleConnectionDetails()

# render a quarto template report with the results in the 
# example database for targetId 1, comparatorId 2 and outcomeId 3.
generatePresentationMultiple(
    server = conDet$server(),
    username = conDet$user(),
    password = conDet$password(),
    dbms = conDet$dbms,
    resultsSchema = 'main',
    targetId = 1,
    targetName = 'target',
    cmSubsetId = 2,
    sccsSubsetId = NULL,
    indicationName = NULL,
    outcomeIds = 3,
    outcomeNames = 'outcome',
    comparatorIds = 2,
    comparatorNames = 'comparator',
    covariateIds = NULL,
    details = list(
      studyPeriod = 'All Time',
      restrictions = "Age - None"
    ),
    title = 'Example results repport',
    lead = 'John Doe',
    date = Sys.Date(),
    backgroundText = '',
    evaluationText = '',
  outputLocation = file.path(getwd(), "extras/reportTest"),
  outputName = paste0('presentation_', gsub(':', '_',gsub(' ','_',as.character(date()))),'.html')
)

Technology

OhdsiReportGenerator is an R package.

System Requirements

Running the package requires R and Java.

License

OhdsiReportGenerator is licensed under Apache License 2.0.

Development

OhdsiReportGenerator is being developed in R Studio.