ml: sls Maximum Likelihood

Description Usage Arguments Value

View source: R/ml.R

Description

Calculates maximum likelihood

Usage

1
2
3
ml(loglik_function = get_logliks(), brts, start_pars = c(0.5, 0.3, 0.5,
  0.3), n_0 = 2, cond = 1, verbose = TRUE, optim_ids = rep(TRUE,
  length(start_pars)), true_pars = start_pars)

Arguments

loglik_function

the loglik function you want to use

brts

branchin times

start_pars

parameters to start from for the search of the likelihood maximum

n_0

starting number of lineages

cond

type of conditioning:

  • cond = 0 no conditiong;

  • cond = 1 conditions on the survival of crown descendents;

  • cond = 2 not available;

  • cond = 3 conditions on the survival of subclade and on the other crown descendents in the main clade;

  • cond = 4 conditions on the survival of the subclade and both crown descendents in the main clade;

verbose

set it to TRUE if you want to see the outputs on screen

optim_ids

ids of the parameters you want to optimize.

true_pars

true parameter values when running the ml process.

Value

best parameters


richelbilderbeek/splendid documentation built on May 20, 2019, 9:42 a.m.