Closed joshyam-k closed 8 months ago
saving this snippet of code that will help with some of the new prediction work
predict_test <- function(lmmod, glmmod, .data, domain_level) {
lookup <- setNames(
lmmod@u,
model.frame(lmmod)[[domain_level]] |>
unique() |>
as.vector()
)
.data |>
mutate(!!domain_level := lookup[.data[[domain_level]]])
}
closing
future_map
andmap
respectively and thus any population data does not need to get passed to eitherpredictions options: