setup_infection_histories | R Documentation |
Given a matrix of antibody data, proposes plausible initial infection histories from which to begin MCMC sampling. The idea is to move along time in the context of antigenic drift and look at an individual's antibody level against each biomarker ID Where antibody levels are raised, we suggest an infection. However, to avoid suggesting multiple infections for regions of high antigenic similarity, we place a necessary gap (defined by 'space') between proposed infection times.
setup_infection_histories(
antibody_data,
possible_exposure_times,
space = 5,
antibody_cutoff = 2,
sample_prob = 0.9
)
antibody_data |
the matrix of titres data with columns for individual, sample, and antibody level |
possible_exposure_times |
vector of real times for all strains |
space |
how many epochs must separate proposed infections |
antibody_cutoff |
specifies how high the antibody level must be to imply an infection |
sample_prob |
if antibody levels suggest an infection, then add an infection with 1 minus this probability |
an nxm matrix of infection histories containing 1s and 0s, where n is the number of individuals and m is the number of time periods for potential infection
Other setup_infection_histories:
setup_infection_histories_antibody_level()
data(example_antibody_data)
data(example_antigenic_map)
start_inf <- setup_infection_histories(example_antibody_data, example_antigenic_map$inf_times)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.