R/fun.model.lm.optim.R

fun.model.lm.optim <-
function (value, x, y, param) 
{
    len <- length(value)
    gld.val <- fun.mean.convert(c(0, value[(len - 2):len]), param)
    resid <- y - x %*% value[-c((len - 2):len)]
    resid <- resid - mean(resid)
    r <- sum(log(dgl(resid, gld.val, param = param))) * -1
    return(r)
}

Try the GLDreg package in your browser

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

GLDreg documentation built on May 13, 2022, 9:06 a.m.