swh:1:snp:9492dda1ea1583c5fa5285d6ddcd2ab9f57129b4
Tip revision: f1b70643dbff13c6cf921e801f1cdd3e2f1a5641 authored by Patrick Mair on 11 November 2012, 00:00:00 UTC
version 0.15-1
version 0.15-1
Tip revision: f1b7064
test_info.R
test_info <- function(ermobject,theta=seq(-5,5,0.01))
##Calculates info of a scale of items
#
#@input: ermobject ... Object of class eRm
# theta ... supporting or sampling points on latent trait
#@output: a list where each element corresponds to an item and contains
# $c.info...matrix of category information in columns for theta (rows)
# $i.info...vector of item information at values of theta
#@author: Thomas Rusch
#@date:12.6.2011
#
{
infos <- item_info(ermobject,theta)
tmp <- lapply(infos, function(x) x$i.info)
tmp <- matrix(unlist(tmp),ncol=dim(ermobject$X)[2])
tinfo <- rowSums(tmp)
return(tinfo)
}