# Load data and create an eim object for the electoral district of "NIEBLA"
eim_obj <- get_eim_chile(elect_district = "NIEBLA", remove_mismatch = FALSE)
# Use it to run the EM algorithm
result <- run_em(eim_obj, allow_mismatch = TRUE)
# Use it with group aggregation
agg_result <- get_agg_proxy(
object = eim_obj,
sd_threshold = 0.05,
allow_mismatch = TRUE,
seed = 123
)
agg_result$group_agg
Run the code above in your browser using DataLab