powered by
Summarise variables using a set of estimate functions. The output will be a formatted summarised_result object.
summariseResult( table, group = list(), includeOverallGroup = FALSE, strata = list(), includeOverallStrata = TRUE, variables = NULL, estimates = c("min", "q25", "median", "q75", "max", "count", "percentage"), counts = TRUE, weights = NULL )
A summarised_result object with the summarised data of interest.
Table with different records.
List of groups to be considered.
TRUE or FALSE. If TRUE, results for an overall group will be reported when a list of groups has been specified.
List of the stratifications within each group to be considered.
TRUE or FALSE. If TRUE, results for an overall strata will be reported when a list of strata has been specified.
Variables to summarise, it can be a list to point to different set of estimate names.
Estimates to obtain, it can be a list to point to different set of variables.
Whether to compute number of records and number of subjects.
Name of the column in the table that contains the weights to be used when measuring the estimates.
# \donttest{ library(PatientProfiles) library(dplyr) cdm <- mockPatientProfiles() x <- cdm$cohort1 |> addDemographics() |> collect() result <- summariseResult(x) mockDisconnect(cdm = cdm) # }
Run the code above in your browser using DataLab