R/llmult.R

llmult <-
function (p, g) 
{
    index <- cbind(seq(along = g), as.numeric(g))
    p <- p[index]
    -2 * sum(log(p[p > .Machine$double.eps]))
}

Try the mda package in your browser

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

mda documentation built on July 9, 2023, 7:14 p.m.