View source: R/pick_time_refs.R
| pick_time_refs | R Documentation |
Identify time period referents within each cohort.
pick_time_refs(
df,
cohort_var,
cohort_ref,
time_var,
intervention_var = NULL,
time_offset = -1
)
df |
A data frame containing the variables in the model. |
cohort_var |
String specifying the name of the column in |
cohort_ref |
An optional string specifying the value of |
time_var |
String specifying the name of the column in |
intervention_var |
String specifying the name of the column in |
time_offset |
Integer specifying which time period relative to the intervention time period should be used as the referent for each cohort. Defaults to -1, which corresponds to the time period immediately preceding intervention. |
list
pick_time_refs(hosp, "cohort", "0", "yr", "intervention_yr")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.