site_aggr | R Documentation |
Calculates visit_med75, n_pat_with_med75 and mean_ae_site_med75
site_aggr(df_visit, method = "med75_adj", min_pat_pool = 0.2, check = TRUE)
df_visit |
dataframe with columns: study_id, site_number, patnum, visit, n_ae |
method |
character, one of c("med75", "med75_adj") defining method for defining evaluation point visit_med75 (see details), Default: "med75_adj" |
min_pat_pool |
double, minimum ratio of available patients available for sampling. Determines maximum visit_med75 value see Details. Default: 0.2 |
check |
logical, perform data check and attempt repair with check_df_visit(), computationally expensive on large data sets. Default: TRUE |
For determining the visit number at which we are going to evaluate AE reporting we take the maximum visit of each patient at the site and take the median. Then we multiply with 0.75 which will give us a cut-off point determining which patient will be evaluated. Of those patients we will evaluate we take the minimum of all maximum visits hence ensuring that we take the highest visit number possible without excluding more patients from the analysis. In order to ensure that the sampling pool for that visit is large enough we limit the visit number by the 80% quantile of maximum visits of all patients in the study.
dataframe with the following columns:
study identification
site identification
number of patients, site level
adjusted median(max(visit)) * 0.75 see Details
number of patients that meet visit_med75 criterion, site level
mean AE at visit_med75, site level
df_visit <- sim_test_data_study(
n_pat = 100,
n_sites = 5,
frac_site_with_ur = 0.4,
ur_rate = 0.6
)
df_visit$study_id <- "A"
df_site <- site_aggr(df_visit)
df_site %>%
knitr::kable(digits = 2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.