| summary.seroincidence {serocalculator} | R Documentation |
Summarizing fitted seroincidence models
Description
This function is a summary() method for seroincidence objects.
Usage
## S3 method for class 'seroincidence'
summary(object, coverage = 0.95, ...)
Arguments
object |
a |
coverage |
desired confidence interval coverage probability |
... |
unused |
Value
a tibble::tibble() containing the following:
-
est.start: the starting guess for incidence rate -
ageCat: the age category we are analyzing -
incidence.rate: the estimated incidence rate, per person year -
CI.lwr: lower limit of confidence interval for incidence rate -
CI.upr: upper limit of confidence interval for incidence rate -
coverage: coverage probability -
log.lik: log-likelihood of the data used in the call toest.incidence(), evaluated at the maximum-likelihood estimate of lambda (i.e., atincidence.rate) -
iterations: the number of iterations used -
antigen_isos: a list of antigen isotypes used in the analysis -
nlm.convergence.code: information about convergence of the likelihood maximization procedure performed bynlm()(see "Value" section ofstats::nlm(), componentcode); codes 3-5 indicate issues:1: relative gradient is close to zero, current iterate is probably solution.
2: successive iterates within tolerance, current iterate is probably solution.
3: Last global step failed to locate a point lower than x. Either x is an approximate local minimum of the function, the function is too non-linear for this algorithm, or
stepmininest.incidence()(a.k.a.,steptolinstats::nlm()) is too large.4: iteration limit exceeded; increase
iterlim.5: maximum step size
stepmaxexceeded five consecutive times. Either the function is unbounded below, becomes asymptotic to a finite value from above in some direction orstepmaxis too small.
Examples
library(dplyr)
xs_data <- load_pop_data("https://osf.io/download//n6cp3/") %>%
clean_pop_data()
curve <- load_curve_params("https://osf.io/download/rtw5k/") %>%
filter(antigen_iso %in% c("HlyE_IgA", "HlyE_IgG")) %>%
slice(1:100, .by = antigen_iso) # Reduce dataset for the purposes of this example
noise <- load_noise_params("https://osf.io/download//hqy4v/")
est1 <- est.incidence(
pop_data = xs_data %>% filter(Country == "Pakistan"),
curve_param = curve,
noise_param = noise %>% filter(Country == "Pakistan"),
antigen_isos = c("HlyE_IgG", "HlyE_IgA")
)
summary(est1)