number_by {redist} | R Documentation |
Renumber districts to match a quantity of interest
Description
District numbers in simulated plans are by and large random. This function will renumber the districts across all simulated plans in order of a provided quantity of interest.
Usage
number_by(data, x, desc = FALSE)
Arguments
data |
a |
x |
|
desc |
|
Value
a modified redist_plans
object. New district numbers will be
stored as an ordered factor variable in the district
column. The
district numbers in the plan matrix will match the levels of this factor.
[Package redist version 4.2.0 Index]