This data format represents information about the antibody kinetics

Format

A list with the following columns:

names

Unique identifier for each exposure type.

model

Description of the model using the makeModel and addAbkineticsModel functions.

prior

Description of the prior distribution using the add_par_df function.

Details

Add more data about this model here.

See also

makeModel, addAbkineticsModel, add_par_df, for related functions.

Author

David Hodgson

Examples

# Example usage. This describes the antibody kinetics for a SARS-CoV-2 delta wave using IgG data. First define the antibody kinetics function:

infSerumKinetics <- function(titre_est, timeSince, pars) {
   a <- pars[1] 
   b <- pars[2] 
   c <- pars[3]
   if (timeSince < 14) {
       titre_est <- titre_est + (log(exp(a) + exp(c)) * (timeSince) / 14);
   } else {
       titre_est <- titre_est + (log(exp(a) * exp(-b/10 * (timeSince - 14))) + exp(c));
   }
   titre_est
}

# Now define the antibody kinetics function in the format required for the rjmc package:

abkineticsModel <- list(
   names = c("delta"),
   model = makeModel(
           addAbkineticsModel("IgG", "delta", TRUE, c("a_d", "b_d", "c_d"), infSerumKinetics)
       ),
   prior = dplyr::bind_rows(
       add_par_df("a_d", -2, 2, "norm",  0, 1), # ab kinetics
       add_par_df("b_d", 0, 1, "norm",  0.3, 0.05), # ab kinetics
       add_par_df("c_d", 0, 4, "unif", 0,  4) # ab kinetics
   )
)