plot_data: Useful plot for looking at simulated data

plot_dataR Documentation

Useful plot for looking at simulated data

Description

Plots measured titres and known infection histories for all individuals, facetted by sample time (multi-strain panel) or virus variable (longitidunal single strain)

Usage

plot_data(
  titre_dat,
  infection_histories,
  strain_isolation_times,
  n_indivs,
  start_inf = NULL,
  study_design = "multi-strain"
)

Arguments

titre_dat

the data frame of titre data

infection_histories

the infection history matrix

strain_isolation_times

the vector of times at which individuals could be infected

n_indivs

how many individuals to plot

start_inf

if not NULL, plots the infection history matrix used as the starting point in the MCMC chain

study_design

default "multi-strain" facets by sample time. "single-strain" gives sample time on the x-axis and colours by virus

Value

a ggplot object

See Also

Other infection_history_plots: calculate_infection_history_statistics(), generate_cumulative_inf_plots(), plot_infection_histories_long(), plot_infection_histories(), plot_infection_history_chains_indiv(), plot_infection_history_chains_time(), plot_number_infections(), plot_posteriors_infhist(), plot_total_number_infections()

Examples

## Not run: 
data(example_titre_dat)
data(example_inf_hist)
data(example_antigenic_map)
strain_isolation_times <- example_antigenic_map$inf_times
plot_data(example_titre_dat, example_inf_hist, strain_isolation_times, 5)

## End(Not run)

seroanalytics/serosolver documentation built on April 24, 2023, 9:52 a.m.