50% off | Unlimited Data & AI Learning
Get 50% off unlimited learning

R0 (version 1.3-1)

fit.epid: Poisson log-likelihood for an observed epidemic

Description

Computes the Poisson log-likelihood of an observed epidemic, compared to the expected incidence values for a given R and generation time distirbution.

Usage

fit.epid(log.R, epid, GT, import, pred = FALSE, offset = 0)

Value

The Poisson log-likelihood of the observed epidemic passed as argument epid, or the Poisson-predicted incidence series given R and GT values.

Arguments

log.R

The log-reproduction ratio.

epid

An epidemic curve, in the sense of passing check.incid() validations. It must have at least an incidence vector in an incid component.

GT

Generation time distribution from generation.time().

import

Vector of imported cases

pred

Boolean. By default (FALSE), the function returns the corresponding log-likelihood. When set to TRUE, the function will return the Poisson-predicted incidence series instead.

offset

Offset value for the log-likelihood (used to calculate confidence intervals).

Author

Pierre-Yves Boelle, Thomas Obadia

Details

For internal use. Called from est.R0.ML().

Computes and returns the Poisson log-likelihood of an observed epidemic, conditional on a given value of R and a generation time distribution.