Constructs an CohortPrevalenceAnalysis object with the specified settings.

createCohortPrevalenceAnalysis(
  analysisId,
  prevalentCohort,
  periodOfInterest,
  lookBackOptions,
  numeratorType,
  denominatorType,
  minimumObservationLength = 0L,
  useOnlyFirstObservationPeriod = FALSE,
  multiplier = 100000L,
  strata = NULL,
  demographicConstraints = createDemographicConstraints(),
  populationCohort = NULL
)

Arguments

analysisId

Unique integer analysisId to identify the analysis (required).

prevalentCohort

A PrevalenceCohort object specifying the cohort of interest (required).

periodOfInterest

A PeriodOfInterest object (required).

numeratorType

Character string specifying numerator type. Must be one of:

  • "pn1": Patients who have been observed to have the condition of interest on the first day of the period of interest or within the lookback time

  • "pn2": patients who have been observed to have the condition of interest at any time in the period of interest or within the lookback time

denominatorType

A DenominatorType object (required).

useOnlyFirstObservationPeriod

Logical: TRUE to restrict analysis to the first observation period (optional).

multiplier

Integer specifying prevalence multiplier (optional).

strata

Character string. Must be one, or some of: "age", "gender", "race" (optional).

demographicConstraints

a DemoConstraint object specifying the constraints of the population.

populationCohort

A CohortPopulation object specifying the population of interest on which to compute prevalence.

lookbackOptions

A LookBackOption object (required).

minimumObservationLength:

Integer specifying minimum observation length (optional).

Value

A CohortPrevalenceAnalysis R6 object.