Skip to content

Commit

Permalink
drop not required .row_id
Browse files Browse the repository at this point in the history
  • Loading branch information
seabbs committed Dec 2, 2024
1 parent c2d46ee commit 6464e95
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions R/marginal_model.R
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ as_epidist_marginal_model.epidist_linelist_data <- function(
orig_relative_obs_time = .data$obs_time - .data$ptime_lwr,
delay_lwr = .data$stime_lwr - .data$ptime_lwr,
delay_upr = .data$stime_upr - .data$ptime_lwr,
.row_id = dplyr::row_number(),
n = 1
)

Expand Down Expand Up @@ -78,14 +77,13 @@ assert_epidist.epidist_marginal_model <- function(data, ...) {
assert_data_frame(data)
assert_names(names(data), must.include = c(
"pwindow", "swindow", "delay_lwr", "delay_upr", "n",
".row_id", "relative_obs_time"
"relative_obs_time"
))
assert_numeric(data$pwindow, lower = 0)
assert_numeric(data$swindow, lower = 0)
assert_integerish(data$delay_lwr)
assert_integerish(data$delay_upr)
assert_numeric(data$relative_obs_time)
assert_integerish(data$.row_id, lower = 1)
if (!all(abs(data$delay_upr - (data$delay_lwr + data$swindow)) < 1e-10)) {
cli::cli_abort(
"delay_upr must equal delay_lwr + swindow"
Expand Down

0 comments on commit 6464e95

Please sign in to comment.