sirt (version 1.9-0)

mcmc.2pno: MCMC Estimation of the Two-Parameter Normal Ogive Item Response Model

Description

This function estimates the Two-Parameter normal ogive item response model by MCMC sampling (Johnson & Albert, 1999, p. 195ff.).

Usage

mcmc.2pno(dat, weights=NULL , burnin = 500, iter = 1000, N.sampvalues = 1000, 
      progress.iter = 50, save.theta = FALSE)

Arguments

dat
Data frame with dichotomous item responses
weights
An optional vector with student sample weights
burnin
Number of burnin iterations
iter
Total number of iterations
N.sampvalues
Maximum number of sampled values to save
progress.iter
Display progress every progress.iter-th iteration. If no progress display is wanted, then choose progress.iter larger than iter.
save.theta
Should theta values be saved?

Value

  • A list of class mcmc.sirt with following entries:
  • mcmcobjObject of class mcmc.list
  • summary.mcmcobjSummary of the mcmcobj object. In this summary the Rhat statistic and the mode estimate MAP is included. The variable PercSEratio indicates the proportion of the Monte Carlo standard error in relation to the total standard deviation of the posterior distribution.
  • burninNumber of burnin iterations
  • iterTotal number of iterations
  • a.chainSampled values of $a_i$ parameters
  • b.chainSampled values of $b_i$ parameters
  • theta.chainSampled values of $\theta_p$ parameters
  • deviance.chainSampled values of Deviance values
  • EAP.relEAP reliability
  • personData frame with EAP person parameter estimates for $\theta_p$ and their corresponding posterior standard deviations
  • datUsed data frame
  • weightsUsed student weights
  • ...Further values

Details

The two-parameter normal ogive item response model with a probit link function is defined by $$P(X_{pi} = 1 | \theta_p ) = \Phi ( a_i \theta_p - b_i ) \quad , \quad \theta_p \sim N(0,1)$$ Note that in this implementation non-informative priors for the item parameters are chosen (Johnson & Albert, 1999, p. 195ff.).

References

Johnson, V. E., & Albert, J. H. (1999). Ordinal Data Modeling. New York: Springer.

See Also

S3 methods: summary.mcmc.sirt, plot.mcmc.sirt For estimating the 2PL model with marginal maximum likelihood see rasch.mml2 or smirt. A hierarchical version of this model can be estimated with mcmc.2pnoh.

Examples

Run this code
#############################################################################
# EXAMPLE 1: Dataset Reading
#############################################################################
data(data.read)
# estimate 2PNO with MCMC with 3000 iterations and 500 burn-in iterations
mod <- mcmc.2pno( dat=data.read , iter=3000 , burnin=500 )
# plot MCMC chains
plot( mod$mcmcobj , ask=TRUE )
# write sampled chains into codafile
mcmclist2coda( mod$mcmcobj , name = "dataread_2pno" )
# summary
summary(mod)

#############################################################################
# SIMULATED EXAMPLE 2
#############################################################################
# simulate data
N <- 1000
I <- 10
b <- seq( -1.5 , 1.5 , len=I )
a <- rep( c(1,2) , I/2 )
theta1 <- rnorm(N)
dat <- sim.raschtype( theta=theta1 , fixed.a =a , b=b )

#***
# Model 1: estimate model without weights
mod1 <- mcmc.2pno( dat , iter= 1500 , burnin=500)
mod1$summary.mcmcobj
plot( mod1$mcmcobj , ask=TRUE )

#***
# Model 2: estimate model with weights
# define weights
weights <- c( rep( 5 , N/4 ) , rep( .2 , 3/4*N ) )
mod2 <- mcmc.2pno( dat , weights=weights , iter= 1500 , burnin=500)
mod1$summary.mcmcobj

Run the code above in your browser using DataLab