Assembles the four components of an OHDSI cohort definition into a single
Cohort object that can be serialized to Circe-compatible JSON via
toCohortJson or written to disk with writeCohort.
cohort(entry, attrition = NULL, exit = NULL, era = NULL)A Cohort S4 object.
giBleed <- cs(descendants(192671L), name = "GI Bleed")
ch <- cohort(
entry = entry(conditionOccurrence(giBleed), primaryCriteriaLimit = "First"),
exit = exit(endStrategy = observationExit())
)