R/startlba.R

Defines functions startlba

Documented in startlba

# starting value generation for lba models

startlba <- function(rt, resp, ...) {
    
    sddr <- sd(rt)    
    drift <- mean(resp)
    nond <- min(rt)/2
    qrt <- quantile(rt)
    bound <- drift*(qrt[4]-nond)
    sp <- drift*(qrt[2]-nond)
    
    return(pars=c(sddr=sddr, sp=sp, bound=bound-sp, nond=nond, drift=drift))
}

Try the glba package in your browser

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

glba documentation built on May 2, 2019, 4:43 p.m.