Create Weighted Adjacency Data

redist.wted.adj(map = NULL, plans = NULL)

Arguments

map

redist_map

plans

redist_plans

Value

tibble

Examples

data(iowa)
shp <- redist_map(iowa, existing_plan = cd_2010, pop_tol = 0.01)
plans <- redist_smc(shp, 100)
#> SEQUENTIAL MONTE CARLO
#> Sampling 100 99-unit maps with 4 districts and population between 753,973 and 769,205.
#> 
Split [0/3]  | ETA?

#> 
Split [3/3] ■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■  | ETA 0s

#> 
redist.wted.adj(shp, plans = plans)
#> Simple feature collection with 222 features and 3 fields
#> Geometry type: LINESTRING
#> Dimension:     XY
#> Bounding box:  xmin: 4192400 ymin: 2974700 xmax: 5729100 ymax: 3978000
#> Projected CRS: NAD83(HARN) / Iowa North (ftUS)
#> # A tibble: 222 × 4
#> # Rowwise: 
#>        i     j                           geometry    wt
#>  * <int> <int>      <LINESTRING [US_survey_foot]> <dbl>
#>  1     1     2 (4654501 3220689, 4590239 3111565)  0.91
#>  2     1    15 (4654501 3220689, 4529015 3222722)  0.83
#>  3     1    39 (4654501 3220689, 4647780 3349436)  0.83
#>  4     1    61 (4654501 3220689, 4779626 3219592)  0.69
#>  5     1    88 (4654501 3220689, 4716357 3109639)  0.85
#>  6     2    15 (4590239 3111565, 4529015 3222722)  0.92
#>  7     2    69 (4590239 3111565, 4464101 3114115)  0.98
#>  8     2    87 (4590239 3111565, 4589159 3005137)  0.88
#>  9     2    88 (4590239 3111565, 4716357 3109639)  0.76
#> 10     3    22 (5486111 3937993, 5500145 3778167)  0.98
#> # … with 212 more rows