execute a large-scale characterization study
Source:R/RunCharacterization.R
runCharacterizationAnalyses.Rd
Specify the database connection containing the CDM data, the cohort database schemas/tables, the characterization settings and the directory to save the results to
Usage
runCharacterizationAnalyses(
connectionDetails,
targetDatabaseSchema,
targetTable,
outcomeDatabaseSchema,
outcomeTable,
tempEmulationSchema = getOption("sqlRenderTempEmulationSchema"),
cdmDatabaseSchema,
characterizationSettings,
outputDirectory,
executionPath = file.path(outputDirectory, "execution"),
csvFilePrefix = "c_",
databaseId = "1",
showSubjectId = FALSE,
minCellCount = 0,
incremental = TRUE,
threads = 1,
minCharacterizationMean = 0.01
)
Arguments
- connectionDetails
The connection details to the database containing the OMOP CDM data
- targetDatabaseSchema
Schema name where your target cohort table resides. Note that for SQL Server, this should include both the database and schema name, for example 'scratch.dbo'.
- targetTable
Name of the target cohort table.
- outcomeDatabaseSchema
Schema name where your outcome cohort table resides. Note that for SQL Server, this should include both the database and schema name, for example 'scratch.dbo'.
- outcomeTable
Name of the outcome cohort table.
- tempEmulationSchema
Some database platforms like Oracle and Impala do not truly support temp tables. To emulate temp tables, provide a schema with write privileges where temp tables can be created
- cdmDatabaseSchema
The schema with the OMOP CDM data
- characterizationSettings
The study settings created using
createCharacterizationSettings
- outputDirectory
The location to save the final csv files to
- executionPath
The location where intermediate results are saved to
- csvFilePrefix
A string to append the csv files in the outputDirectory
- databaseId
The unique identifier for the cdm database
- showSubjectId
Whether to include subjectId of failed rechallenge case series or hide
- minCellCount
The minimum count value that is calculated
- incremental
If TRUE then skip previously executed analyses that completed
- threads
The number of threads to use when running aggregate covariates
- minCharacterizationMean
The minimum mean threshold to extract when running aggregate covariates
Details
The results of the characterization will be saved into an sqlite database inside the specified saveDirectory
See also
Other LargeScale:
createCharacterizationSettings()
,
loadCharacterizationSettings()
,
saveCharacterizationSettings()
Examples
conDet <- exampleOmopConnectionDetails()
drSet <- createDechallengeRechallengeSettings(
targetIds = c(1,2),
outcomeIds = 3
)
cSet <- createCharacterizationSettings(
dechallengeRechallengeSettings = drSet
)
runCharacterizationAnalyses(
connectionDetails = conDet,
targetDatabaseSchema = 'main',
targetTable = 'cohort',
outcomeDatabaseSchema = 'main',
outcomeTable = 'cohort',
cdmDatabaseSchema = 'main',
characterizationSettings = cSet,
outputDirectory = tempdir()
)
#> Removing 2 previously completed jobs
#> No jobs left