invtrf {lazy.irt}R Documentation

Inverse Function of trf

Description

Inverse Function of trf

Usage

invtrf(
  param,
  x = NULL,
  xmin = NULL,
  xmax = NULL,
  by_x = 1,
  weight = NULL,
  theta = NULL,
  thmin = -5,
  thmax = 5,
  npoints = 121,
  method = 0,
  interpol = "spline",
  print = 0,
  plot = 0
)

Arguments

param

Item parameter data frame

x

The value of x, the observed test score, or NULL

xmin

The minimum value of x, or NULL

xmax

The maximum value of x, or NULL

by_x

The increment of x values

weight

The weight data frame or the vector of item weight, or NULL

theta

The value of theta for method=0, or NULL

thmin

The minimum value of theta for method=0, or NULL

thmax

The maximum value of theta for method=0, or NULL

npoints

The # of theta points for method=0

method

= 1 to use native uniroot function (slow)
= 0 to use interpolation with option lazy.tools::interpol (fast).

interpol

The interpolation method. See lazy.tools::interpol.

print

= 2 to print the result

plot

= 1 to plot the result

Details

The test response function, trf, is calculated as:

 trf(theta) = sum_{j=1}^n w_j x sum_{k=0}^{ncat[i]-1} v_{kj} P_{kj}(theta)
 where
 w_j is the item weight for item j, (default=1)
 v_{kj} is the item category weight for the k-th category of item j.
 The default value of v_{kj} = k, k=0, 1, 2, ... ncat[i]-1

When values x=NULL the value of x will be calculated using the weight information.

If x is too small or too large, -9999 or 9999 will be returned.

Value

A list of
x The value of x.
theta The value of theta.
locminmax A list containing the locations of -9999 or 9999.

Examples

res <- invtrf( paramS1, method=1, print=2 )
res <- invtrf( paramS1, method=0, print=2 )
res <- invtrf( paramS1, weight=weightS12, method=1, print=2 )
res <- invtrf( paramS1, weight=weightS12, method=0, print=2 )

res <- invtrf( paramS1, by_x=0.5, print=2 )
res <- invtrf( paramS1, weight=c(1,1,2,2), print=2 )


[Package lazy.irt version 0.1.6 ]