Open cwhittaker1000 opened 7 months ago
Low priority as we'll use the empirical approach based on bootstrapping UK households for now.
See https://mrc-ide.github.io/helios/articles/helios.html#households for illustration of issue.
After exposing function can use the following to verify problem:
df <- data.frame(individual_households, age_class_vector)
just_child <- 0
just_child_list <- list()
for(i in individual_households) {
household <- df[df$individual_households == i, ]
if(all(household$age_class_vector == "child")) {
just_child <- just_child + 1
just_child_list[[i]] <- household$age_class_vector
}
}
names(just_child_list) <- seq_along(just_child_list)
just_child_list[sapply(just_child_list, is.null)] <- NULL
just_child_list
just_child
I got
> just_child
[1] 381
Made some progress on this on the branch just-child-bug
but didn't get to a fix
@athowes and @tbreweric what do we think about just removing the non-empirical version of this function from the package?
As above, bug fix required