From c1c09bab741f38c88369e482d3693cb6298cf82d Mon Sep 17 00:00:00 2001 From: James Hay <9113187+jameshay218@users.noreply.github.com> Date: Mon, 13 May 2024 16:52:09 +0100 Subject: [PATCH] Fixed plot_pointrange to remove unnecessary warnings --- R/plot_infection_histories.R | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/R/plot_infection_histories.R b/R/plot_infection_histories.R index 5c6b87e..9d2de33 100644 --- a/R/plot_infection_histories.R +++ b/R/plot_infection_histories.R @@ -327,8 +327,6 @@ plot_attack_rates_pointrange <- function(infection_histories, antibody_data=NULL colnames(quantiles)[which(colnames(quantiles) == "tested")] <- "Biomarker tested" p <- ggplot(quantiles[quantiles$population_group %in% group_subset, ]) + - scale_y_continuous(expand = c(0, 0)) + - scale_x_continuous(breaks = year_breaks, labels = year_labels) + coord_cartesian(ylim=c(0,1)) + theme_classic() + ylab("Estimated attack rate") + @@ -389,8 +387,7 @@ plot_attack_rates_pointrange <- function(infection_histories, antibody_data=NULL } if (!plot_residuals) { p <- p + - scale_y_continuous(expand = c(0, 0)) + - coord_cartesian(ylim=c(0,1)) + scale_y_continuous(expand = c(0, 0)) } if (by_group) {