
Summarise the number of people in observation during a specific interval of time
Source:R/summariseInObservation.R
summariseInObservation.RdUsage
summariseInObservation(
observationPeriod,
interval = "overall",
output = "record",
ageGroup = NULL,
sex = FALSE,
dateRange = NULL
)Arguments
- observationPeriod
An observation_period omop table. It must be part of a cdm_reference object.
- interval
Time interval to stratify by. It can either be "years", "quarters", "months" or "overall".
- output
Output format. It can be either the number of records ("record") that are in observation in the specific interval of time, the number of person-days ("person-days"), the number of subjects ("person"), the number of females ("sex") or the median age of population in observation ("age").
- ageGroup
A list of age groups to stratify the results by. Each element represents a specific age range. You can give them specific names, e.g.
ageGroup = list(children = c(0, 17), adult = c(18, Inf)).- sex
Logical; whether to stratify results by sex (
TRUE) or not (FALSE).- dateRange
A vector of two dates defining the desired study period. Only the
start_datecolumn of the OMOP table is checked to ensure it falls within this range. IfdateRangeisNULL, no restriction is applied.