Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop ggpubr dependency #215

Merged
merged 6 commits into from
Nov 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ Imports:
Matrix,
pbapply,
ggplot2,
ggpubr,
DRDID (>= 1.1.0),
generics,
methods,
Expand All @@ -30,4 +29,5 @@ Suggests:
plm,
here,
knitr,
covr
covr,
backports
1 change: 0 additions & 1 deletion NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ export(trimmer)
import(BMisc)
import(data.table)
import(ggplot2)
import(ggpubr)
import(stats)
import(utils)
importFrom(DRDID,drdid_panel)
Expand Down
4 changes: 3 additions & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
# did 2.2.0
# did 2.2.0 (development version)

* Code improvements that made the package faster and more memory efficient

* Improved automated testing and regression testing

* Check if data is balanced if `panel = TRUE` and `allow_unbalanced_panel = TRUE`. If it is, disable `allow_unbalanced_panel` and proceed with panel data setup. This is different from the previous behavior, which would always proceed as if `panel = FALSE`.

* Significantly reduced the number of recursive package dependencies, enabling faster installation times and a smaller build footprint.

# did 2.1.2

* Added wrapper function for HonestDiD package
Expand Down
8 changes: 4 additions & 4 deletions R/gplot.R
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,15 @@ gplot <- function(ssresults, ylim=NULL, xlab=NULL, ylab=NULL, title="Group", xga
p <- p + geom_hline(aes(yintercept = ref_line), linetype = 'dashed')
}
if (theming) {
p <- p + ggpubr::theme_pubr() +
p <- p + theme_classic() +
theme(plot.title = element_text(color="darkgray", face="bold", size=12),
axis.title = element_text(color="darkgray", face="bold", size=12),
strip.background = element_rect(fill = 'white', color = 'white'),
strip.text = element_text(color = 'darkgray', face = 'bold', size = 12, hjust = 0),
legend.position = 'bottom')
}
if (!legend) {
p <- p + ggpubr::rremove("legend")
p <- p + theme(legend.position = "none")
}

p
Expand Down Expand Up @@ -94,14 +94,14 @@ splot <- function(ssresults, ylim=NULL, xlab=NULL, ylab=NULL, title="Group",
p <- p + geom_vline(aes(xintercept = ref_line), linetype = 'dashed')
}
if (theming) {
p <- p + ggpubr::theme_pubr() +
p <- p + theme_classic() +
theme(plot.title = element_text(color="darkgray", face="bold", size=12),
axis.title = element_text(color="darkgray", face="bold", size=12),
legend.position = 'none')
}

if (!legend) {
p <- p + ggpubr::rremove("legend")
p <- p + theme(legend.position = "none")
}

p
Expand Down
1 change: 0 additions & 1 deletion R/imports.R
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
#' @import stats
#' @import utils
#' @import ggplot2
#' @import ggpubr
#' @import BMisc
#' @import data.table
#' @importFrom tidyr gather
Expand Down
Loading