comp_log_st {redistmetrics} | R Documentation |
Calculate Log Spanning Tree Compactness
Description
Calculate Log Spanning Tree Compactness
Usage
comp_log_st(plans, shp, counties = NULL, adj)
Arguments
plans |
A |
shp |
A |
counties |
column name in shp containing counties |
adj |
Zero-indexed adjacency list. Not required if a |
Value
A numeric vector. Can be shaped into a district-by-plan matrix.
References
Cory McCartan and Kosuke Imai. 2020. Sequential Monte Carlo for Sampling Balanced and Compact Redistricting Plans.
Examples
data(nh)
data(nh_m)
# For a single plan:
comp_log_st(plans = nh$r_2020, shp = nh, counties = county, adj = nh$adj)
# Or many plans:
comp_log_st(plans = nh_m[, 3:5], shp = nh, counties = county, adj = nh$adj)
[Package redistmetrics version 1.0.7 Index]