Calculate multiplicative beta scaling factor for schools. We assume here that schools has come from spim_simulate_control but we may add validation later.

spim_beta_mult_schools(dates, schedule, modifier, region)

Arguments

dates

A sircovid date, fractional dates (e.g. 100.25) are allowed.

schedule

A data.frame of school open/closed information. Required columns are region, date and schools; really this should have been sorted out by spim_simulate_control

modifier

The amount to decrease beta by when schools are closed for holidays etc. A value of 0.15 is a 15% reduction in contacts, or a multiplicative beta of 0.85

region

The region to subset from the schedule.

Value

A vector the same length as dates with the scaling factor.