Skip to content

Commit

Permalink
Update R/new_regimen.R
Browse files Browse the repository at this point in the history
Co-authored-by: Jasmine Hughes <[email protected]>
  • Loading branch information
JordanBrooks33 and jasmineirx authored Jun 6, 2024
1 parent 92313ae commit 5bbf857
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/new_regimen.R
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ new_regimen <- function(
stop("'covariate' is a protected type and cannot be used for doses.")
}
if(any(type == "infusion") && (is.null(t_inf) || length(t_inf) == 0)) {
reg$t_inf[reg$type=="infusion"] = 1
reg$t_inf[reg$type == "infusion"] <- 1
} else if (any(is.na(t_inf))) {
reg$t_inf[(reg$type=="infusion" & is.na(t_inf))] <- 1
}
Expand Down

0 comments on commit 5bbf857

Please sign in to comment.