Learn R Programming

infutil (version 1.0)

iota: Lindley Information (i.e., Information Utility) of Item Response Patterns

Description

This function calculates Lindley information (i.e., information utility) quantities for item response patterns, including the Lindley information for individual response patterns and the expected information for a set of response patterns.

Usage

iota(ltm.obj, logL.fun, fscore.obj = NULL, data = NULL, prior = NULL, theta0 = NULL, range.int = c(-Inf, Inf), range.theta = c(-10, 10))

Arguments

ltm.obj
An object representing an IRT model of a set of items, from the ltm package (e.g., using the ltm, grm, or gpcm functions).
logL.fun
A function returning the log-likelihood for a response vector (see details).
fscore.obj
A factor.scores from the ltm package.
data
A matrix of response patterns.
prior
A prior density function, taking a quantile and returning its density.
theta0
Optional. A latent trait value, vector of values, "max.prior" (see details), or NULL. theta0 = NULL by default.
range.int
The range to integrate over in calculating the marginal likelihood and Lindley information.
range.theta
The range of the latent variable to search over if theta0="max.prior" is specified.

Value

A list with the following elements:
I
The expected Lindley information over the set of response patterns.
I.x
The vector of Lindley information values for each response pattern.
p.x
The marginal probabilities for each response pattern.
Additionally, if theta0 is not NULL:
logL0
The vector of log-likelihoods for the latent trait values specified by theta0.
logNL0.pval
The p-values for the null hypothesis test of no change from prior to posterior probability of the latent trait values specified by theta0.

Details

This function will calculate Lindley information values for each response pattern in a set, and return the expected Lindley information for the set as a whole. It will also optionally return the log-likelihood value for a hypothesized latent trait value of interest, together with the significance of the change from prior to posterior probability of that trait value.

A set of response patterns must be supplied, using either a factor.scores object or a data matrix. A prior density function must also be supplied.

Additionally, either ltm.obj or logL.fun must be supplied. If a log-likelihood function is supplied directly, it must take three arguments: z, a vector of latent trait values, dat, a data matrix, and i, a row index. logL.fun must return the vector of log-likelihoods for the vector of latent trait values, for a single response pattern (i.e., the function must return the vector of log-likelihoods for the trait vector z, for the response pattern in row i of data matrix dat).

iota will also optionally return a p-value for the null hypothesis of no change from the prior to posterior probability of a specific latent trait value. theta0 specifies the latent trait value. If theta0 is a scalar, it is assumed to be the latent trait value of interest. If theta0 is a vector, it must be equal in length to the number of unique response patterns in fscore.obj or data, where each value in the vector is assumed to correspond to each response pattern. Finally, the latent trait with the greatest prior density (over the range range.theta) can be specified with theta0="max prior". By default, theta0=NULL, specifying that no log-likelihods or p-values should be returned.

Note that currently, range.int must be within [-10, 10] for grm and gpcm objects. If a grm or gpcm object is supplied and range.int is outside this range, the range will be reset to [-10, 10].

References

Markon, K. E. (2013). Information utility: Quantifying the total psychometric information provided by a measure. Psychological Methods, 18, 15-35. doi: 10.1037/a0030638..

See Also

Jeffreys, ltm, grm, gpcm, factor.scores

Examples

Run this code
ltm.lsat <- ltm(LSAT~z1, IRT=FALSE)
Nu.lsat = nrow(unique(LSAT))
	
iota(ltm.lsat, data=LSAT, prior=Jeffreys(ltm.lsat))
iota(ltm.lsat, data=LSAT, prior=Jeffreys(ltm.lsat), theta0=c("max.prior"))
iota(ltm.lsat, data=LSAT, prior=Jeffreys(ltm.lsat), theta0=0)
iota(ltm.lsat, data=LSAT, prior=Jeffreys(ltm.lsat), theta0=rnorm(Nu.lsat))
	

Run the code above in your browser using DataLab