Skip to contents

This function generates the generation time distribution for cholera from a gamma distribution with shape mean_generation_time / 10 and a FIXED rate of 0.1 per day, so only the shape responds to the mean (and the coefficient of variation, \(1/\sqrt{shape}\), changes with it). The day-wise and week-wise tables are saved as CSV files.

Usage

get_generation_time_distribution(PATHS, mean_generation_time)

Arguments

PATHS

A list containing the paths where the output tables will be saved. Typically generated by the get_paths() function and should include:

  • MODEL_INPUT: Path to the directory where model input data will be saved.

  • DOCS_TABLES: Path to the directory where day-wise and week-wise generation time tables will be saved.

mean_generation_time

A numeric value representing the desired mean generation time (in days); sets the gamma shape (mean_generation_time / 10) at a fixed rate of 0.1.

Details

The day-wise table (pred_generation_time_days.csv, column y) holds the gamma density evaluated at days 1-56, not a probability mass function: it is not normalised and omits the mass below day 1 and beyond day 56 (at a mean of 5 days it sums to about 0.74). Only the week-wise table (Probability) is normalised to sum to 1. This is a legacy kernel: the reproductive-number calculations (calc_Reff) derive their generation-interval kernels from the model parameters and do not read these files.