Skip to content

Commit

Permalink
improve pml()$call
Browse files Browse the repository at this point in the history
  • Loading branch information
KlausVigo committed Nov 19, 2024
1 parent 3daabfe commit 6126689
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions R/phylo.R
Original file line number Diff line number Diff line change
Expand Up @@ -1440,6 +1440,12 @@ pml <- function(tree, data, bf = NULL, Q = NULL, inv = 0, k = 1, shape = 1,
USER = df + (kmax > 1) + (inv0 > 0) + length(unique(bf)) - 1 +
length(unique(Q)) - 1)

extras <- pairlist(bf = bf, Q = Q, inv = inv, shape = shape, rate = rate, k=k,
model=model, g=g, w=w, site.rate = site.rate, ASC = ASC,
dnds=dnds, tstv=tstv)
existing <- names(call)[names(call) %in% names(extras)]
for (a in existing) call[[a]] <- extras[[a]]

result <- list(logLik = tmp$loglik, inv = inv, k = kmax, shape = shape,
Q = Q, bf = bf, rate = rate, siteLik = tmp$siteLik, weight = weight,
g = g, w = w, eig = eig, data = data, model = model, INV = INV,
Expand Down

0 comments on commit 6126689

Please sign in to comment.