R/rm_sdt_calc_gradient_likelihood_item_llgrad2.R

Defines functions rm_sdt_calc_gradient_likelihood_item_llgrad2

## File Name: rm_sdt_calc_gradient_likelihood_item_llgrad2.R
## File Version: 0.18

rm_sdt_calc_gradient_likelihood_item_llgrad2 <- function(logprob_D1, nik.item, diffindex, K,
    prob_D1_dim )
{
    nik_item <- as.vector(nik.item)
    logprob_D1 <- as.vector(logprob_D1)
    ll_grad <- sirt_rcpp_rm_sdt_calc_gradient_likelihood_item_llgrad( logprob_D1=logprob_D1,
                    prob_D1_dim=prob_D1_dim, nik_item=nik_item )
    ll_grad <- rowsum(ll_grad, diffindex )
    ll_grad <- ll_grad[ rownames(ll_grad) > 0, 1 ]
    return(ll_grad)
}

Try the sirt package in your browser

Any scripts or data that you put into this service are public.

sirt documentation built on May 29, 2024, 8:43 a.m.