Skip to content

Commit

Permalink
Restore count_var
Browse files Browse the repository at this point in the history
  • Loading branch information
Bisaloo committed Apr 11, 2024
1 parent c005edb commit 5a7fab4
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,10 @@ Here we identify the key data needed in the analyses, including:
```{r}
date_var <- "date"
group_var <- "region"
# Leave count_var as NULL if the data is really a linelist / patient-level data.
# Update count_var to a character string with the name of the column if the data
# is already aggregated.
count_var <- NULL
dat <- dat_raw %>%
make_linelist(
Expand All @@ -321,6 +325,7 @@ This section creates epidemic curves ("_epicurves_"), with or without stratifica
dat_i <- dat_raw %>%
incidence("date",
interval = params$epicurve_unit,
counts = count_var,
groups = group_var
)
Expand Down Expand Up @@ -451,6 +456,7 @@ i_recent <- dat_raw %>%
dat_i_day <- dat_raw %>%
incidence("date",
interval = "daily",
counts = count_var,
groups = group_var
) %>%
keep_first(n_distinct(.$date_index) - params$incomplete_days)
Expand Down

0 comments on commit 5a7fab4

Please sign in to comment.