From 20d55f95586f1f1e0b5d8aff59eedaffde431cd0 Mon Sep 17 00:00:00 2001 From: Joshua Lambert Date: Fri, 24 May 2024 13:41:47 +0100 Subject: [PATCH] remove spacing from barplot in plot.epidist and specifying ylim for discrete cdf --- R/plot.R | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/R/plot.R b/R/plot.R index 48702323e..560a06f16 100644 --- a/R/plot.R +++ b/R/plot.R @@ -104,17 +104,18 @@ plot.epidist <- function(x, if (cumulative) { graphics::barplot( height = cdf(x, q = unique(round(xlim))), - space = 0.2, + space = 0, names.arg = unique(round(xlim)), xlab = xlab, ylab = "", + ylim = c(0, 1), main = "Cumulative Distribution Function", ... ) } else { graphics::barplot( density(x, at = unique(round(xlim))), - space = 0.2, + space = 0, names.arg = unique(round(xlim)), xlab = xlab, ylab = "",