benchmarkCohortSurvival {CohortSurvival} | R Documentation |
Estimate performance of estimateSurvival function for benchmarking
Description
Estimate performance of estimateSurvival function for benchmarking
Usage
benchmarkCohortSurvival(
cdm,
targetSize,
outcomeSize,
outcomeDateVariable = "cohort_start_date",
competingOutcomeSize = NULL,
competingOutcomeDateVariable = "cohort_start_date",
censorOnCohortExit = FALSE,
censorOnDate = NULL,
followUpDays = Inf,
strata = NULL,
eventGap = 30,
estimateGap = 1,
minCellCount = 5,
returnParticipants = FALSE
)
Arguments
cdm |
CDM reference |
targetSize |
number of people in the target cohort table |
outcomeSize |
number of people in the outcome cohort table |
outcomeDateVariable |
Variable containing date of outcome event |
competingOutcomeSize |
number of people in the competing outcome cohort table |
competingOutcomeDateVariable |
Variable containing date of competing event |
censorOnCohortExit |
If TRUE, an individual's follow up will be censored at their cohort exit |
censorOnDate |
if not NULL, an individual's follow up will be censored at the given date |
followUpDays |
Number of days to follow up individuals (lower bound 1, upper bound Inf) |
strata |
strata |
eventGap |
Days between time points for which to report survival estimates. First day will be day zero with risk estimates provided for times up to the end of follow-up, with a gap in days equivalent to eventGap. |
estimateGap |
vector of time points at which to give survival estimates, if NULL estimates at all times are calculated |
minCellCount |
The minimum number of events to reported, below which results will be obscured. If 0, all results will be reported. |
returnParticipants |
Either TRUE or FALSE. If TRUE, references to participants from the analysis will be returned allowing for further analysis. |
Value
tibble with performance of estimateSurvival function information, according to the selected input parameters
Examples
cdm <- mockMGUS2cdm()
cdm$condition_occurrence <- cdm$death_cohort %>%
dplyr::rename("condition_start_date" = "cohort_start_date",
"condition_end_date" = "cohort_end_date") %>%
dplyr::compute()
surv_timings <- benchmarkCohortSurvival(
cdm, targetSize = 100, outcomeSize = 20)