Skip to content

Commit

Permalink
Fix plot_branch_counts()
Browse files Browse the repository at this point in the history
Error caused due to count columns as character vectors instead of
integer vectors.

Fixed, now works.
  • Loading branch information
allenbaron committed Nov 5, 2024
1 parent 804caee commit a596dc2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions R/plot.R
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ plot_branch_counts <- function(DO_repo, out_dir = "graphics/website",
dplyr::rename("Total" = "count")
df <- dplyr::left_join(asserted, total, by = "branch") %>%
dplyr::mutate(
dplyr::across(.cols = c("Asserted", "Total"), .fns = as.integer),
Inferred = .data$Total - .data$Asserted,
branch = stringr::str_to_title(
stringr::str_remove(.data$branch, "disease (of|by) ")
Expand Down

0 comments on commit a596dc2

Please sign in to comment.