View source: R/IntersectCohorts.R
intersectCohorts | R Documentation |
Find the common cohort period for persons present in all the cohorts. Note: if subject is not found in any of the cohorts, then they will not be in the final cohort.
intersectCohorts(
connectionDetails = NULL,
connection = NULL,
sourceCohortDatabaseSchema = NULL,
sourceCohortTable,
targetCohortDatabaseSchema = NULL,
targetCohortTable,
cohortIds,
newCohortId,
purgeConflicts = FALSE,
tempEmulationSchema = getOption("sqlRenderTempEmulationSchema")
)
connectionDetails |
An object of type |
connection |
An object of type |
sourceCohortDatabaseSchema |
Schema name where your source cohort tables reside. Note that for SQL Server, this should include both the database and schema name, for example 'scratch.dbo'. |
sourceCohortTable |
The name of the source cohort table. |
targetCohortDatabaseSchema |
Schema name where your target cohort tables reside. Note that for SQL Server, this should include both the database and schema name, for example 'scratch.dbo'. |
targetCohortTable |
The name of the target cohort table. |
cohortIds |
A vector of one or more Cohort Ids. |
newCohortId |
The cohort id of the output cohort. |
purgeConflicts |
If there are conflicts in the target cohort table i.e. the target cohort table already has records with newCohortId, do you want to purge and replace them with transformed. By default - it will not be replaced, and an error message is thrown. |
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. |
Nothing is returned
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.