DW-NOMINATE dynamic weighted ideal-point estimator
Source:R/spatial_voting.R
morie_spatial_voting_dw_nominate.RdGaussian-error NOMINATE variant supporting comparable scores across legislative sessions.
References
Poole, K. T. and Rosenthal, H. (1997). Congress: A Political- Economic History of Roll Call Voting. Oxford University Press.
Examples
set.seed(1)
v <- matrix(stats::rbinom(20 * 30, 1, 0.5), 20, 30)
morie_spatial_voting_dw_nominate(v, max_iter = 20)
#> $ideal_points
#> [,1] [,2]
#> [1,] 0.4537455 -0.018924111
#> [2,] 0.2404942 -0.200967769
#> [3,] 0.1552407 -0.114181151
#> [4,] 0.3661386 0.130901572
#> [5,] 0.4132845 0.040973512
#> [6,] 0.2790701 -0.012366485
#> [7,] 0.2071679 -0.195088903
#> [8,] 0.4277600 -0.097057151
#> [9,] 0.2665432 0.066829947
#> [10,] 0.4583470 -0.257635342
#> [11,] 0.4051705 -0.181237721
#> [12,] 0.2187379 0.067019314
#> [13,] 0.0690283 -0.187653057
#> [14,] 0.3410390 -0.293620469
#> [15,] 0.1952023 -0.202651136
#> [16,] 0.2783036 -0.004212361
#> [17,] 0.2820336 -0.029940699
#> [18,] 0.2178203 0.134208927
#> [19,] 0.2628522 -0.029355626
#> [20,] 0.4202374 -0.201705488
#>
#> $dim_weights
#> [,1]
#> [1,] 0.5
#> [2,] 0.5
#>
#> $normal_vectors
#> [,1] [,2]
#> [1,] -0.91052820 0.41344698
#> [2,] -0.60241584 0.79818241
#> [3,] 0.07676569 0.99704916
#> [4,] 0.95509183 0.29630996
#> [5,] -0.40992195 -0.91212060
#> [6,] 0.88208311 0.47109382
#> [7,] 0.76872502 -0.63957942
#> [8,] 0.91993661 -0.39206713
#> [9,] -0.23852354 0.97113672
#> [10,] 0.99956858 -0.02937108
#> [11,] -0.63614434 -0.77157007
#> [12,] 0.58945401 0.80780194
#> [13,] 0.24811657 -0.96873018
#> [14,] 0.81823607 0.57488236
#> [15,] -0.70039694 -0.71375355
#> [16,] 0.50034073 -0.86582859
#> [17,] 0.95017235 -0.31172504
#> [18,] -0.47435355 -0.88033443
#> [19,] -0.52860725 0.84886652
#> [20,] -0.23624507 -0.97169350
#> [21,] 0.68635092 -0.72727052
#> [22,] 0.50885875 -0.86085003
#> [23,] 0.01973469 0.99980525
#> [24,] -0.48713080 -0.87332902
#> [25,] -0.05537721 0.99846550
#> [26,] 0.90661429 -0.42196034
#> [27,] 0.78434332 -0.62032697
#> [28,] -0.15072976 -0.98857500
#> [29,] 0.95292401 0.30320923
#> [30,] -0.03691794 -0.99931830
#>
#> $cutpoints
#> [,1]
#> [1,] -0.29893066
#> [2,] -0.22736995
#> [3,] -0.06444229
#> [4,] 0.25638446
#> [5,] -0.03867829
#> [6,] 0.22273257
#> [7,] 0.26228860
#> [8,] 0.30018420
#> [9,] -0.15799033
#> [10,] 0.28150919
#> [11,] -0.12759059
#> [12,] 0.11368253
#> [13,] 0.16989723
#> [14,] 0.22184080
#> [15,] -0.11536862
#> [16,] 0.22391448
#> [17,] 0.28985395
#> [18,] -0.06183441
#> [19,] -0.20644566
#> [20,] 0.01517740
#> [21,] 0.23728800
#> [22,] 0.21495166
#> [23,] -0.06487880
#> [24,] -0.06023408
#> [25,] -0.08575182
#> [26,] 0.27621723
#> [27,] 0.28110440
#> [28,] 0.02883028
#> [29,] 0.24365983
#> [30,] 0.06359641
#>
#> $log_lik
#> [1] -341.4907
#>
#> $gmp
#> [1] 0.7033333
#>
#> $n_dims
#> [1] 2
#>