From ec71cddfd1579d486cd347c15a589322958cb4bc Mon Sep 17 00:00:00 2001 From: "Zachary S.L. Foster" Date: Mon, 29 Jul 2024 09:54:09 -0700 Subject: [PATCH] fix bug when NAs are present in core gene phylo labels --- assets/main_report/index.qmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets/main_report/index.qmd b/assets/main_report/index.qmd index 18d9e005..3b0ef8cf 100644 --- a/assets/main_report/index.qmd +++ b/assets/main_report/index.qmd @@ -291,7 +291,7 @@ plot_one <- function(x) { print(core_plots[[x]]) } tip_count <- sum(core_plots[[1]]$data$isTip) -max_label_size <- max(nchar(core_plots[[1]]$data$label)) +max_label_size <- max(nchar(core_plots[[1]]$data$label, keepNA = FALSE)) print_figures_with_selector(plot_one, selector = list('Color By' = names(core_plots)), id_prefix = 'core-gene-phylo', width = 1700 + max_label_size * 30, height = 500 + tip_count * 60, res = 300) ```