R/binary-cov-loglike.R
bp_loglike_binary_cov.Rd
Calculate the likelihood for binary covariate MC trees
bp_loglike_binary_cov( inf_params, mc_samples_summary, return_neg = FALSE, multiple_outside_transmissions = FALSE, messages = FALSE )
inf_params | vector of length 2, the beta0 and beta1 coefficients |
---|---|
mc_samples_summary | a data frame of sampled transmission trees with the following columns, where the last one is only needed for the multiple outsider model. |
return_neg | logical indicating whether to return the negative loglike. Default is FALSE |
multiple_outside_transmissions | logical indicating whether to use the outsider model li kelihood or not |
messages | logical indicating whether we should print messages. Default is FALSE. |
the estimated log average likelihood over the observed clusters