Skip to contents

Computes Poole-Rosenthal NOMINATE utilities and vote probabilities.

Usage

morie_spatial_voting_nominate_utility(x, z_yea, z_nay, beta = 15, w = NULL)

Arguments

x

Legislator ideal points (n_leg x n_dims).

z_yea

Yea outcome locations (n_votes x n_dims).

z_nay

Nay outcome locations (n_votes x n_dims).

beta

Signal-to-noise ratio.

w

Dimension weights (length n_dims; defaults to 1).

Value

List with U_yea, U_nay, utility_diff, vote_probs.

References

Poole, K. T. and Rosenthal, H. (1985); Armstrong et al. (2021), Ch. 5.

Examples

set.seed(1)
x  <- matrix(rnorm(8), 4, 2)
zy <- matrix(rnorm(6), 3, 2); zn <- matrix(rnorm(6), 3, 2)
morie_spatial_voting_nominate_utility(x, zy, zn)
#> $U_yea
#>          [,1]       [,2]       [,3]
#> [1,] 7.268466  9.0661481 0.05993645
#> [2,] 6.677455 13.0479148 2.34933989
#> [3,] 5.513776  7.0490910 0.02477633
#> [4,] 8.395039  0.9778193 0.19097495
#> 
#> $U_nay
#>           [,1]      [,2]      [,3]
#> [1,]  2.679623 11.224246 12.023793
#> [2,]  2.031255  3.797543  5.407910
#> [3,]  1.977829 10.378562 10.661535
#> [4,] 13.148638  3.894100  4.051964
#> 
#> $utility_diff
#>           [,1]      [,2]       [,3]
#> [1,]  4.588843 -2.158098 -11.963856
#> [2,]  4.646201  9.250372  -3.058570
#> [3,]  3.535947 -3.329471 -10.636759
#> [4,] -4.753599 -2.916281  -3.860989
#> 
#> $vote_probs
#>             [,1]       [,2]         [,3]
#> [1,] 0.989937668 0.10357690 6.370307e-06
#> [2,] 0.990493247 0.99990393 4.484893e-02
#> [3,] 0.971693451 0.03457389 2.401618e-05
#> [4,] 0.008546933 0.05135459 2.061332e-02
#>