R/alpha.u.R

Defines functions alpha.u

Documented in alpha.u

alpha.u = function(nu, a0, b0, H){
  M = length(nu)
  a = a0 + M*(H-1)
  b = b0 - sum(unlist(lapply(nu, function(x){log(1-x[-H])})))

  return(rgamma(1, a, b))
}

Try the BHTSpack package in your browser

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

BHTSpack documentation built on Feb. 8, 2021, 5:07 p.m.