iterate_match {vaccineff} | R Documentation |
This function iterates to re-match registers that were
removed after adjusting exposure times. To avoid generating the
same pairs already removed, each iteration is split in two steps,
one for the removed vaccinated population and the other for the
unvaccinated. A tryCatch
validation handles errors when no matches
can be generated due to the lack of treated or untreated individuals.
The threshold for the maximum number of iterations is the total
removed population for the first iteration. The algorithm iterates
until no new adjusted pairs are generated or the maximum number of
iterations is reached.
iterate_match(
all,
matched,
adjusted,
outcome_date_col,
censoring_date_col,
immunization_date_col,
vacc_status_col,
vaccinated_status,
unvaccinated_status,
exact,
nearest,
start_cohort,
end_cohort
)
all |
|
matched |
|
adjusted |
|
outcome_date_col |
Name of the column that contains the outcome dates. |
censoring_date_col |
Name of the column that contains the censoring date. |
immunization_date_col |
Name of the column that contains the
immunization date to set the beginning of the follow-up period
( |
vacc_status_col |
Name of the column containing the vaccination. |
vaccinated_status |
Status assigned to the vaccinated population. |
unvaccinated_status |
Status assigned to the unvaccinated population. |
exact |
Name(s) of column(s) for |
nearest |
Named vector with name(s) of column(s) for |
start_cohort |
Start date of the study. |
end_cohort |
End date of the study. |
data.frame
with adjusted pairs after iterating.