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

Remove Tidyverse dependency #22

Merged
merged 6 commits into from
Dec 8, 2023
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
17 changes: 9 additions & 8 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,24 @@ Imports:
broom (>= 0.5.6),
dplyr (>= 1.0.0),
forecast (>= 8.0),
lubridate (>= 1.6.0),
tibble (>= 1.2),
tidyr (>= 1.0.0),
timetk (>= 2.1.0),
rlang,
tidyverse,
tidyquant
rlang
Suggests:
forcats,
ggplot2,
knitr,
lubridate,
rmarkdown,
testthat,
testthat (>= 2.0.0),
purrr,
readr,
stringr,
scales,
fracdiff
fracdiff,
tidyr (>= 1.0.0),
tidyquant,
zoo
RoxygenNote: 7.2.3
Roxygen: list(markdown = TRUE)
VignetteBuilder: knitr
Config/testthat/edition: 2
6 changes: 5 additions & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
# sweep (development version)

* sweep no longer imports tidyverse. (@olivroy, #22)

* Remove internal usage of `dplyr::select_()`. (@olivroy, #22)

# sweep 0.2.5

- Fixes to get `sweep` back on CRAN following inadvertent `timetk` archival.
* Fixes to get `sweep` back on CRAN following inadvertent `timetk` archival.

# sweep 0.2.4

Expand Down
1 change: 0 additions & 1 deletion R/sw_sweep.R
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@
#'
#' @examples
#' library(forecast)
#' library(sweep)
#' library(dplyr)
#'
#' # ETS forecasts
Expand Down
1 change: 0 additions & 1 deletion R/sw_tidy.R
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
#' @examples
#' library(dplyr)
#' library(forecast)
#' library(sweep)
#'
#' WWWusage %>%
#' auto.arima() %>%
Expand Down
1 change: 0 additions & 1 deletion R/sweep-package.R
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#' To learn more about `sweep`, start with the vignettes:
#' `browseVignettes(package = "sweep")`
#'
#' @aliases sweep-package
#' @keywords internal
"_PACKAGE"

Expand Down
1 change: 0 additions & 1 deletion R/tidiers_HoltWinters.R
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#' @examples
#' library(dplyr)
#' library(forecast)
#' library(sweep)
#'
#' fit_hw <- USAccDeaths %>%
#' stats::HoltWinters()
Expand Down
1 change: 0 additions & 1 deletion R/tidiers_StructTS.R
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#' @examples
#' library(dplyr)
#' library(forecast)
#' library(sweep)
#'
#' fit_StructTS <- WWWusage %>%
#' StructTS()
Expand Down
1 change: 0 additions & 1 deletion R/tidiers_arima.R
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
#' @examples
#' library(dplyr)
#' library(forecast)
#' library(sweep)
#'
#' fit_arima <- WWWusage %>%
#' auto.arima()
Expand Down
1 change: 0 additions & 1 deletion R/tidiers_bats.R
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#' @examples
#' library(dplyr)
#' library(forecast)
#' library(sweep)
#'
#' fit_bats <- WWWusage %>%
#' bats()
Expand Down
1 change: 0 additions & 1 deletion R/tidiers_decomposed_ts.R
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
#' @examples
#' library(dplyr)
#' library(forecast)
#' library(sweep)
#'
#' fit_decomposed <- USAccDeaths %>%
#' decompose()
Expand Down
1 change: 0 additions & 1 deletion R/tidiers_ets.R
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
#' @examples
#' library(dplyr)
#' library(forecast)
#' library(sweep)
#'
#' fit_ets <- WWWusage %>%
#' ets()
Expand Down
1 change: 0 additions & 1 deletion R/tidiers_nnetar.R
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
#' @examples
#' library(dplyr)
#' library(forecast)
#' library(sweep)
#'
#' fit_nnetar <- lynx %>%
#' nnetar()
Expand Down
2 changes: 1 addition & 1 deletion R/utils-broom.R
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ add_index <- function(ret, rename_index) {

# Rearrange index
ret <- ret %>%
dplyr::select_(rename_index, "dplyr::everything()")
dplyr::relocate(dplyr::all_of(rename_index))

return(ret)

Expand Down
1 change: 0 additions & 1 deletion README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ knitr::opts_chunk$set(
```

```{r, echo=FALSE}
library(tidyverse)
library(tidyquant)
library(sweep)
```
Expand Down
1 change: 0 additions & 1 deletion man/sw_sweep.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion man/sw_tidy.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/sweep-package.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion man/tidiers_HoltWinters.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion man/tidiers_StructTS.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion man/tidiers_arima.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion man/tidiers_bats.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion man/tidiers_decomposed_ts.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion man/tidiers_ets.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion man/tidiers_nnetar.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 8 additions & 6 deletions tests/testthat.R
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
# This file is part of the standard setup for testthat.
# It is recommended that you do not modify it.
#
# Where should you do additional test configuration?
# Learn more about the roles of various files in:
# * https://r-pkgs.org/testing-design.html#sec-tests-files-overview
# * https://testthat.r-lib.org/articles/special-files.html

library(testthat)
library(sweep)
library(timetk)
library(forecast)
library(tidyverse)
library(lubridate)
library(tidyquant)
library(fracdiff)

test_check("sweep")
Loading