Description Usage Arguments Value
Utility function to compute onset week based on a trajectory of incidence values
1 2  | get_onset_week(incidence_trajectory, baseline, onset_length,
  first_season_week = 31, weeks_in_first_season_year)
 | 
incidence_trajectory | 
 a numeric vector with incidence for each time point in a season  | 
baseline | 
 the threshold that incidence must cross to count as an onset  | 
onset_length | 
 number of consecutive time points that incidence must exceed the baseline threshold in order to count as the season onset  | 
first_season_week | 
 number of weeks in year corresponding to the first week in the season. For example, our code takes this value to be 31: a new influenza season starts on the 31st week of each year.  | 
weeks_in_first_season_year | 
 How many MMWR weeks are in the first year of the season? For example, in the 2000/2001 season, the first year is 2000. There were 52 MMWR weeks in 2000.  | 
the smallest index i such that every entry of incidence_trajectory[seq(from = i, length = onset_length)] is >= baseline, if such an index exists. Otherwise, the character vector "none"
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.