R/asr-musse.R

Defines functions make.asr.marginal.musse

Documented in make.asr.marginal.musse

## (1) Marginal ASR:
## This should work without modification for:
##   musse
##   musse.split
##   musse.t
##   musse.td
make.asr.marginal.musse <- function(lik, ...) {
  e <- environment(lik)
  f.pars <- e$f.pars
  do.asr <- make.do.asr.marginal(e$all_branches, e$rootfunc)
  asr <- function(pars, nodes=NULL, condition.surv=TRUE,
                  root=ROOT.FLAT, root.p=NULL, ...) {
    pars2 <- f.pars(pars)
    do.asr(pars2, nodes, NULL, # below here extra args to rootfunc:
           condition.surv, root, root.p, intermediates=FALSE)
  }
  asr
}

Try the diversitree package in your browser

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

diversitree documentation built on May 29, 2024, 4:38 a.m.