simRaschdat: Random Dichotomous Rasch Item Data Generator

Description Usage Arguments Value Examples

View source: R/simRaschdat.R

Description

Random Dichotomous Rasch Item Data Generator

Usage

1
simRaschdat(nitem, ilocation = NULL, plocation = NULL, nobs = 0, rnum = 0.5)

Arguments

nitem

The number of items

ilocation

A data matrix of item difficulty parameter specified by user. Default is to generate nitem difficulty parameters from a standard normal distribution with a mean of 0 and sd of 1

plocation

A data matrix of person location parameter specified by user when nobs=0.

nobs

The number of observations or rows in the person location matrix which will be generated from a standard normal distribution with a mean of 0 and sd of 1

rnum

The random number between 0 and 1 to assign the responses. For example, when rnum=0.5, if a person's probability of responding items correctly is less than rnum, 1s will be assigned to the items. If larger than rnum, 0s will be assigned.

Value

A list

Examples

1
2
3
4
5
simRaschdat(10,ilocation=NULL,plocation=rnorm(500,0,1),rnum=0.6)
## Not run: 
simRaschdat(20,nobs=50,rnum=0.6)

## End(Not run)

alanbio/genIRT documentation built on Aug. 4, 2020, 7:51 p.m.