# NOT RUN {
data(iowa)
iowa_map <- redist_map(iowa, existing_plan = cd_2010, total_pop = pop, pop_tol = 0.01)
cons <- flip_constraints_helper(
map = iowa_map, constraint = c('compact', 'vra'),
constraintweight = c(0.05, 10), target_min = 0.05,
target_other = 0.01, group_pop = black
)
redist_flip(iowa_map, 10, constraints = cons)
# }
Run the code above in your browser using DataLab