Skip to content

Commit

Permalink
hotfix: simulate_infection checks
Browse files Browse the repository at this point in the history
  • Loading branch information
sbfnk committed Mar 15, 2024
1 parent 71ada81 commit 3b3b2a7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion R/simulate_infections.R
Original file line number Diff line number Diff line change
Expand Up @@ -75,13 +75,14 @@ simulate_infections <- function(estimates, R, initial_infections,

## check inputs
assert_data_frame(R, any.missing = FALSE)
assert_subset(colnames(R), c("date", "R"))
assert_subset(c("date", "R"), colnames(R))
assert_date(R$date)
assert_numeric(R$R, lower = 0)
assert_numeric(initial_infections, lower = 0)
assert_numeric(day_of_week_effect, lower = 0, null.ok = TRUE)
assert_numeric(pop, lower = 0)
assert_class(delays, "delay_opts")
assert_class(truncation, "trunc_opts")
assert_class(obs, "obs_opts")
assert_class(generation_time, "generation_time_opts")

Expand Down

0 comments on commit 3b3b2a7

Please sign in to comment.