Learn R Programming

emIRT (version 0.0.5)

binIRT: Two-parameter Binary IRT estimation via EM

Description

binaryIRT estimates a binary IRT model with two response categories. Estimation is conducted using the EM algorithm described in the reference paper below. The algorithm will produce point estimates that are comparable to those of ideal, but will do so much more rapidly and also scale better with larger data sets.

Usage

binIRT(.rc, .starts = NULL, .priors = NULL, .D = 1L, .control = NULL)

Arguments

.rc
a list object, in which .rc$votes is a matrix of numeric values containing the data to be scaled. Respondents are assumed to be on rows, and items assumed to be on columns, so the matrix is assumed to be of dimension (N x J). For each item, `1
.starts
a list containing several matrices of starting values for the parameters. The list should contain the following matrices:
  • alpha
{ A (J x 1) matrix of starting values for the item difficulty parameter $alpha$.}

Value

  • An object of class binIRT.
  • meanslist, containing several matrices of point estimates for the parameters corresponding to the inputs for the priors. The list should contain the following matrices.
    • x
    { A (N x 1) matrix of point estimates for the respondent ideal points $x_i$.} beta{ A (J x D+1 ) matrix of point estimates for the item parameters $\alpha$ and $\beta$.}

item

  • .priors
  • x$sigma
  • beta$mu
  • beta$sigma
  • .D
  • .control
  • verbose
  • thresh
  • maxit
  • checkfreq
  • vars
  • beta
  • runtime
  • conv
  • threads
  • tolerance
  • n
  • j
  • d
  • call

itemize

  • iters

eqn

$\beta$

References

Kosuke Imai, James Lo, and Jonathan Olmsted ``Fast Estimation of Ideal Points with Massive Data.'' Working Paper. Available at http://imai.princeton.edu/research/fastideal.html.

See Also

'convertRC', 'makePriors', 'getStarts'.

Examples

Run this code
## Data from 109th US Senate
data(s109)

## Convert data and make starts/priors for estimation
rc <- convertRC(s109)
p <- makePriors(rc$n, rc$m, 1)
s <- getStarts(rc$n, rc$m, 1)

## Conduct estimates
lout <- binIRT(.rc = rc,
                .starts = s,
                .priors = p,
                .control = {
                    list(threads = 1,
                         verbose = FALSE,
                         thresh = 1e-6
                         )
                }
                )

## Look at first 10 ideal point estimates
lout$means$x[1:10]

Run the code above in your browser using DataLab