Description Usage Arguments Value Author(s) References See Also Examples
Generates a matrix of roll call votes based on the assumption that legislators possess either normal (Gaussian) or quadratic utility functions. The roll call votes are then analyzed using the ideal point model described in Carroll, Lewis, Lo, Poole and Rosenthal, “The Structure of Utility in Spatial Models of Voting,” American Journal of Political Science 57(4): 1008–1028. The estimated value of the alpha parameter can be compared to the true value (1 for normal (Gaussian) utility, 0 for quadratic utility).
1 | anominate.sim(nvotes=500, nlegis=101, seed=123345, utility="normal")
|
nvotes |
Number of roll call votes to be simulated |
nlegis |
Number of legislators to be simulated |
seed |
Seed for the random number generator |
utility |
The utility function used to generate the roll call data (“normal” or “quadratic”) |
An object of class rollcall
, a list with the following components:
votes |
a |
codes |
a |
n |
numeric, number of legislators, equal to |
m |
numeric, number of votes, equal to |
legis.data |
user-supplied data on legislators/test-subjects. |
vote.data |
user-supplied data on rollcall votes/test-items. |
desc |
any user-supplied description. If no description was provided,
defaults |
source |
any user-supplied source information (e.g., a url or a
short-form reference). If no description is provided, |
Christopher Hare, Royce Carroll, Jeffrey B. Lewis, James Lo, Keith T. Poole and Howard Rosenthal
Carroll, Royce, Jeffrey B. Lewis, James Lo, Keith T. Poole and Howard Rosenthal. 2013. “The Structure of Utility in Spatial Models of Voting.” American Journal of Political Science 57(4): 1008–1028.
rollcall
for the full documentation of a roll call object from Simon Jackman's pscl
package.
Output from this function is intended for use with anominate
.
1 2 3 4 5 6 7 8 9 10 11 12 | ## Not run:
quadratic.data <- anominate.sim(utility="quadratic")
quad_anom <- anominate(quadratic.data, dims=1, polarity=2, nsamp=200, thin=1,
burnin=100, random.starts=FALSE, verbose=TRUE)
summary(quad_anom)
normal.data <- anominate.sim(utility="normal")
norm_anom <- anominate(normal.data, dims=1, polarity=2, nsamp=200, thin=1,
burnin=100, random.starts=FALSE, verbose=TRUE)
summary(norm_anom)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.