if (FALSE) {
slc <- slicer(n_slices = 2, id_var = "id", data_long = pbc2, data_surv = pbc2.id)
n_cores <- max(parallel::detectCores() - 1L, 1L)
lme_fit <- lme(fixed = log(serBilir) ~ year * sex,
data = slc$long,
random = ~ year | id,
cores = n_cores)
cox_fit <- coxph(formula = Surv(years, status2) ~ sex,
data = slc$surv,
cores = n_cores)
mxm_fit <- mixed_model(fixed = ascites ~ year + sex,
data = slc$long,
random = ~ year | id,
family = binomial(),
cores = n_cores)
}
Run the code above in your browser using DataLab