TAM — tam.mml.3pl" />

This estimates a 3PL model with design matrices for item slopes and item intercepts. Discrete distributions of the latent variables are allowed which can be log-linearly smoothed.

tam.mml.3pl(resp, Y=NULL, group=NULL, formulaY=NULL, dataY=NULL, ndim=1,
  pid=NULL, xsi.fixed=NULL, xsi.inits=NULL, xsi.prior=NULL,
  beta.fixed=NULL, beta.inits=NULL, variance.fixed=NULL, variance.inits=NULL,
  est.variance=TRUE, A=NULL, notA=FALSE, Q=NULL, Q.fixed=NULL, E=NULL,
  gammaslope.des="2PL", gammaslope=NULL, gammaslope.fixed=NULL,
  est.some.slopes=TRUE, gammaslope.max=9.99, gammaslope.constr.V=NULL,
  gammaslope.constr.c=NULL, gammaslope.center.index=NULL,  gammaslope.center.value=NULL,
  gammaslope.prior=NULL, userfct.gammaslope=NULL, gammaslope.constr.Npars=0,
  est.guess=NULL, guess=rep(0, ncol(resp)),
  guess.prior=NULL, max.guess=0.5, skillspace="normal", theta.k=NULL,
  delta.designmatrix=NULL, delta.fixed=NULL, delta.inits=NULL, pweights=NULL,
  item.elim=TRUE, verbose=TRUE, control=list(), Edes=NULL )

# S3 method for tam.mml.3pl
summary(object,file=NULL,...)

# S3 method for tam.mml.3pl
print(x,...)

Arguments

resp

Data frame with polytomous item responses \(k=0,...,K\). Missing responses must be declared as NA.

Y

A matrix of covariates in latent regression. Note that the intercept is automatically included as the first predictor.

group

An optional vector of group identifiers

formulaY

An R formula for latent regression. Transformations of predictors in \(Y\) (included in dataY) can be easily specified, e. g. female*race or I(age^2).

dataY

An optional data frame with possible covariates \(Y\) in latent regression. This data frame will be used if an R formula in formulaY is specified.

ndim

Number of dimensions (is not needed to determined by the user)

pid

An optional vector of person identifiers

xsi.fixed

A matrix with two columns for fixing \(\xi\) parameters. 1st column: index of \(\xi\) parameter, 2nd column: fixed value

xsi.inits

A matrix with two columns (in the same way defined as in xsi.fixed with initial value for \(\xi\).

xsi.prior

Item-specific prior distribution for \(\xi\) parameters. It is assumed that \(\xi_k \sim N( \mu_k, \sigma_k^2 )\). The first column in xsi.prior is \(\mu_k\), the second is \(\sigma_k\).

beta.fixed

A matrix with three columns for fixing regression coefficients. 1st column: Index of \(Y\) value, 2nd column: dimension, 3rd column: fixed \(\beta\) value.
If no constraints should be imposed on \(\beta\), then set beta.fixed=FALSE (see Example 2, Model 2_4).

beta.inits

A matrix (same format as in beta.fixed) with initial \(\beta\) values

variance.fixed

An optional matrix. In case of a single group it is a matrix with three columns for fixing entries in covariance matrix: 1st column: dimension 1, 2nd column: dimension 2, 3rd column: fixed value of covariance/variance. In case of multiple groups, it is a matrix with four columns 1st column: group index (from \(1,\ldots,G\), 2nd column: dimension 1, 3rd column: dimension 2, 4th column: fixed value of covariance

variance.inits

Initial covariance matrix in estimation. All matrix entries have to be specified and this matrix is NOT in the same format like variance.fixed.

est.variance

Should the covariance matrix be estimated? This argument applies to estimated item slopes in tam.mml.2pl. The default is FALSE which means that latent variables (in the first group) are standardized in 2PL estimation.

A

An optional array of dimension \( I \times (K+1) \times N_\xi\). Only \(\xi\) parameters are estimated, entries in \(A\) only correspond to the design.

notA

An optional logical indicating whether all entries in the \(A\) matrix are set to zero and no item intercept \(\xi\) should be estimated.

Q

An optional \(I \times D\) matrix (the Q-matrix) which specifies the loading structure of items on dimensions.

Q.fixed

Optional \(I \times D\) matrix of the same dimensions like Q. Non NA entries contain values at which item loadings should be fixed to.

E

Optional design array for item slopes \(\gamma\). It is a four dimensional array of size \(I \times (K+1) \times D \times N_\gamma\) containing items, categories, dimensions, \(\gamma\) parameter.

gammaslope.des

Optional string indicating type of item slope parameter to be estimated. gammaslope.des="2PL" estimates a slope parameter for an item, gammaslope.des="2PLcat" for an item and a

gammaslope

Initial or fixed vector of \(\gamma\) parameters

gammaslope.fixed

An optional matrix containing fixed values in the \(\gamma\) vector. First column: parameter index; second colunmn: fixed value.

est.some.slopes

An optional logical indicating whether some item slopes should be estimated.

gammaslope.max

Value for absolute entries in \(\gamma\) vector

gammaslope.constr.V

An optional constraint matrix \(V\) for item slope parameters \(\gamma\)

gammaslope.constr.c

An optional constraint vector \(c\) for item slope parameters \(\gamma\)

gammaslope.center.index

Indices of gammaslope parameters which should be fixed to sum specified in gammaslope.center.value (see Example 7).

gammaslope.center.value

Specified values of sum of subset of gammaslope parameters.

gammaslope.prior

Item-specific prior distribution for \(\gamma\) parameters. It is assumed that \(\gamma_k \sim N( \mu_k, \sigma_k^2 )\). The first column in gammaslope.prior is \(\mu_k\), the second is \(\sigma_k\).

userfct.gammaslope

A user specified function for constraints or transformations of the \(\gamma\) parameters within the algorithm. See Example 17 in tam.mml.

gammaslope.constr.Npars

Number of constrained \(\gamma\) parameters in userfct.gammaslope

est.guess

An optional vector of integers indicating for which items a guessing parameter should be estimated. Same integers correspond to same estimated guessing parameters. A value of 0 denotes an item for which no guessing parameter is estimated.

guess

Fixed or initial guessing parameters

guess.prior

Item-specific prior distribution for guessing parameters \(c_i\). It is assumed that \(c_i \sim Beta(a_i, b_i)\). The first column in gammaslope.prior is \(a_i\), the second is \(b_i\).

max.guess

Upper bound for guessing parameters

skillspace

Skill space: normal distribution ("normal") or discrete distribution ("discrete").

theta.k

A matrix of the \(\bold{\theta}\) skill space in case of a discrete distribution (skillspace="discrete").

delta.designmatrix

A design matrix of the log-linear model for the skill space in case of a discrete distribution (skillspace="discrete").

delta.fixed

Fixed \(\delta\) values of the log-linear skill space. delta.fixed must be a matrix with three columns. First column: \(\delta\) parameter index, Second column: Group index, Third column: Fixed \(\delta\) parameter value.

delta.inits

Optional initial matrix of \(\delta\) parameters.

pweights

Optional vector of person weights.

item.elim

Optional logical indicating whether an item with has only zero entries should be removed from the analysis. The default is TRUE.

verbose

Logical indicating whether output should be printed during iterations. This argument replaces control$progress.

control

See tam.mml for more details.

Edes

Compact form of design matrix. This argument is only defined for convenience for models with random starting values to avoid recalculations.

object

Object of class tam.mml.3pl

file

A file name in which the summary output will be written

x

Object of class tam.mml.3pl

...

Further arguments to be passed

Details

The item response model for item \(i\) and category \(h\) and no guessing parameters can be written as $$ P( X_{i}=h | \bold{\theta} ) \propto \exp( \sum_d b_{ihd} \theta_d + \sum_k a_{ih} \xi_k ) $$ For item slopes, a linear decomposition is allowed $$ b_{ihd}=\sum_k e_{ihdk} \gamma_k $$ In case of a guessing parameter, the item response function is $$ P( X_{i}=h | \bold{\theta} )=c_i + ( 1 - c_i ) \cdot ( 1 + \exp( - \sum_d b_{ihd} \theta_d - \sum_k a_{ih} \xi_k ) )^{-1} $$ For possibilities of definitions of the design matrix \(E=(e_{ihdk})\) see Formann (2007), for the strongly related linear logistic latent class model see Formann (1992). Linear constraints on \(\gamma\) can be specified by equations \(V \gamma=c\) and using the arguments gammaslope.constr.V and gammaslope.constr.c.

Like in tam.mml, a multivariate linear regression $$ \bold{\theta}=Y \beta + \bold{\epsilon}$$ assuming a multivariate normal distribution on the residuals \(\bold{\epsilon}\) can be specified (skillspace="normal").

Alternatively, a log-linear distribution of the skill classes \(P(\theta)\) (skillspace="discrete") is performed $$\log P(\theta )=D_{ \delta } \delta $$ See Xu and von Davier (2008). The design matrix \(D_{\delta}\) can be specified in delta.designmatrix. The theta grid \(\bold{\theta}\) of the skill space can be defined in theta.k.

Value

The same output as in tam.mml and additional entries

delta

Parameter vector \(\delta\)

gammaslope

Estimated \(\gamma\) item slope parameters

se.gammaslope

Standard errors \(\gamma\) item slope parameters

E

Used design matrix \(E\)

Edes

Used design matrix \(E\) in compact form

guess

Estimated \(c\) guessing parameters

se.guess

Standard errors \(c\) guessing parameters

References

Formann, A. K. (1992). Linear logistic latent class analysis for polytomous data. Journal of the American Statistical Association, 87, 476-486. doi: 10.2307/2290280

Formann, A. K. (2007). (Almost) Equivalence between conditional and mixture maximum likelihood estimates for some models of the Rasch type. In M. von Davier & C. H. Carstensen (Eds.), Multivariate and mixture distribution Rasch models (pp. 177-189). New York: Springer. doi: 10.1007/978-0-387-49839-3_11

Xu, X., & von Davier, M. (2008). Fitting the structured general diagnostic model to NAEP data. ETS Research Report ETS RR-08-27. Princeton, ETS. doi: 10.1002/j.2333-8504.2008.tb02113.x

Note

The implementation of the model builds on pieces work of Anton Formann. See http://www.antonformann.at/ for more information.

See also

See also tam.mml.

See the CDM::slca function in the CDM package for a similar method.

logLik.tam, anova.tam

Examples