Skip to contents

The cohort comes from compile_circe_to_duckdb() and the features from inst/sql/duckdb_demo_features.sql, which computes the same columns as the GoogleSQL the demo runs on BigQuery. Both tables are written to the connection's current schema. Ids are returned as text, so they are exact whatever the connection's bigint setting.

Usage

run_duckdb_demo(
  con,
  cdm_schema = "main",
  cohort_json = NULL,
  cohort_id = 1L,
  cohort_table = "demo_cohort",
  features_table = "demo_features"
)

Arguments

con

A DuckDB connection holding the CDM.

cdm_schema

Schema holding the CDM tables.

cohort_json

Circe JSON; defaults to the shipped diabetes_phenotype.circe.json.

cohort_id

Cohort definition id.

cohort_table, features_table

Tables to (re)create.

Value

A list with cohort and features data frames.