splits_total: Count the Total Splits in Each Plan

View source: R/splits.R

splits_totalR Documentation

Count the Total Splits in Each Plan

Description

Counts the total number of administrative splits.

Usage

splits_total(plans, shp, admin)

Arguments

plans

redist_plans object or plans_matrix where each row indicates a district assignment and each column is a plan

shp

redist_map object, tibble, or data frame containing other columns

admin

unqouted name of column in shp with numeric identifiers for administrative units

Value

numeric matrix

Examples

data(nh)
data(nh_m)
# For a single plan:
splits_total(plans = nh$r_2020, shp = nh, admin = county)

# Or many plans:
splits_total(plans = nh_m[, 3:5], shp = nh, admin = county)


redistmetrics documentation built on April 11, 2022, 5:08 p.m.