Description Usage Arguments Details Value
This takes in historical hospitalization data (day.vec and num_actual.vec). Given a fixed set of parameters, it finds the Re that gives the least square error with the data.
1 | findBestRe(model, N, start.exp, num.days, day.vec, num_actual.vec, params)
|
model |
String, model to use (either M0, M1, M2) |
N |
Numeric. Number of people in the area. |
start.exp |
Numeric. Starting number of exposures. |
num.days |
Numeric. Number of days to simulate. |
day.vec |
Vector of numerics. |
num_actual.vec |
Vector of numerics. |
params |
List of paramters for SEIR simulation. |
The main inputs are day.vec and num_actual vec. Day.vec consists of indices of the historical days relative to the 'set date.' For example, if the date is set as April 1, 2020, and the user provides data from March 28, 29, and 31, then the day.vec = c(-4, -3, -1)
Num_actual.vec is a vector of the values of historical hospitalizations from those dates.
The function returns a list with 'best.re' (The Re with the best fit) and 'best.vals' (a vector of numerics with projected values of hospitalizations on the historical dates for which data was provided).
List with best Re and the projected number of hospitalizations on the historical dates for which data was provided.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.