Skip to content

Commit

Permalink
Change package name to fabletools ⭐
Browse files Browse the repository at this point in the history
Related: #98
  • Loading branch information
mitchelloharawild committed Jul 30, 2019
1 parent f0c33da commit 5f4753d
Show file tree
Hide file tree
Showing 19 changed files with 46 additions and 41 deletions.
2 changes: 1 addition & 1 deletion .Rbuildignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
^README\.Rmd$
Makefile
^fablelite\.Rproj$
^fabletools\.Rproj$
^\.Rproj\.user$
^\.travis\.yml$
^data-raw$
Expand Down
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Package: fablelite
Package: fabletools
Version: 0.0.0.9100
Title: Core tools for packages in the 'fable' framework
Description: Provides tools, helpers and data structures for developing models and time series functions for the 'fable' framework. These tools support a consistent and tidy interface for time series modelling and analysis.
Expand Down Expand Up @@ -56,7 +56,7 @@ ByteCompile: true
VignetteBuilder: knitr
License: GPL-3
URL: http://fablelite.tidyverts.org/
BugReports: https://github.com/tidyverts/fablelite/issues
BugReports: https://github.com/tidyverts/fabletools/issues
Encoding: UTF-8
LazyData: true
RoxygenNote: 6.1.1
Expand Down
4 changes: 2 additions & 2 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# fablelite 0.1.0
# fabletools 0.1.0

* First release.

Expand All @@ -14,7 +14,7 @@
* Added methods to train a model definition to a dataset. `model()` is the recommended interface, which can fit many model definitions to each time series in the input dataset returning a mable (`mdl_df`). The lower level interface for model estimation is accessible using `estimate()` which will return a time series model (`mdl_ts`), however using this interface is discouraged.

### Forecasting
* Added `forecast()`, which allows you to produce future predictions of a time series from fitted models. The methods provided in fablelite handle the application of new data (such as the future index or exogenous regressors) to model specials, giving a simple and consistent interface to forecasting any model. The forecast methods will automatically backtransform and bias adjust any transformations specified in the model formula. This function returns a fable (`fbl_ts`) object.
* Added `forecast()`, which allows you to produce future predictions of a time series from fitted models. The methods provided in fabletools handle the application of new data (such as the future index or exogenous regressors) to model specials, giving a simple and consistent interface to forecasting any model. The forecast methods will automatically backtransform and bias adjust any transformations specified in the model formula. This function returns a fable (`fbl_ts`) object.
* Added a forecast distribution class (`fcdist`) which is used to describe the distribution of forecasts. Common forecast distributions have been added to the package, including the normal distribution (`dist_normal()`), multivariate normal (`dist_mv_normal()`) and simulated/sampled distributions (`dist_sim()`). In addition to this, `dist_unknown()` is available for methods that don't support distributional forecasts. A new distribution can be added using the `new_fcdist()` function. The forecast distribution class handles transformations on the distribution, and is used to create forecast intervals of the `hilo` class using the `hilo()` function. Mathematical operations on the normal distribution are supported.
* Added tools for working with transformations in models, including automatic back-transformation, transformation classes (`new_transformation()`), and bias adjustment (`bias_adjust()`) methods.
* Added `aggregate_key()`, which is used to compute all levels of aggregation in a specified key structure. It supports nested structures using `parent / key` and crossed structures using `keyA * keyB`.
Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions R/features.R
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ rd_features_tag <- function(){
#' This documentation lists all available in currently loaded packages. This is
#' a useful reference for making a [`feature_set()`] from particular package(s).
#'
#' \Sexpr[stage=render,results=rd]{fablelite:::rd_features_pkg()}
#' \Sexpr[stage=render,results=rd]{fabletools:::rd_features_pkg()}
#'
#' @seealso [features_by_tag]
#'
Expand All @@ -272,7 +272,7 @@ NULL
#' This documentation lists all available in currently loaded packages. This is
#' a useful reference for making a [`feature_set()`] from particular tag(s).
#'
#' \Sexpr[stage=render,results=rd]{fablelite:::rd_features_tag()}
#' \Sexpr[stage=render,results=rd]{fabletools:::rd_features_tag()}
#'
#' @seealso [features_by_pkg]
#'
Expand Down
4 changes: 2 additions & 2 deletions R/model.R
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,11 @@ Check that specified model(s) are model definitions.", nm[which(!is_mdl)[1]]))

if(.safely){
estimate <- function(dt, mdl){
out <- safely(fablelite::estimate)(dt, mdl)
out <- safely(fabletools::estimate)(dt, mdl)
if(is.null(out$result)){
f <- quo(!!mdl$formula)
f <- set_env(f, mdl$env)
out$result <- fablelite::estimate(dt, null_model(!!f))
out$result <- fabletools::estimate(dt, null_model(!!f))
}
out
}
Expand Down
4 changes: 2 additions & 2 deletions R/transform.R
Original file line number Diff line number Diff line change
Expand Up @@ -212,15 +212,15 @@ inverse_table$add("base", "exp",
}
)

inverse_table$add("fablelite", "box_cox",
inverse_table$add("fabletools", "box_cox",
function(operation, target, result){
args <- call_args(operation)
target_pos <- match(list(target), args)
expr(inv_box_cox(!!!replace(args, target_pos, list(result))))
}
)

inverse_table$add("fablelite", "inv_box_cox",
inverse_table$add("fabletools", "inv_box_cox",
function(operation, target, result){
args <- call_args(operation)
target_pos <- match(list(target), args)
Expand Down
14 changes: 7 additions & 7 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,21 @@ knitr::opts_chunk$set(
)
```

# fablelite
[![Travis build status](https://travis-ci.org/tidyverts/fablelite.svg?branch=master)](https://travis-ci.org/tidyverts/fablelite)
[![AppVeyor Build Status](https://ci.appveyor.com/api/projects/status/github/tidyverts/fablelite?branch=master&svg=true)](https://ci.appveyor.com/project/tidyverts/fablelite)
[![Code test coverage](https://codecov.io/gh/tidyverts/fablelite/branch/master/graph/badge.svg)](https://codecov.io/gh/tidyverts/fablelite?branch=master)
# fabletools
[![Travis build status](https://travis-ci.org/tidyverts/fabletools.svg?branch=master)](https://travis-ci.org/tidyverts/fabletools)
[![AppVeyor Build Status](https://ci.appveyor.com/api/projects/status/github/tidyverts/fabletools?branch=master&svg=true)](https://ci.appveyor.com/project/tidyverts/fabletools)
[![Code test coverage](https://codecov.io/gh/tidyverts/fabletools/branch/master/graph/badge.svg)](https://codecov.io/gh/tidyverts/fabletools?branch=master)
[![lifecycle](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://www.tidyverse.org/lifecycle/#experimental)
[![Licence](https://img.shields.io/badge/licence-GPL--3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0.en.html)

The R package *fablelite* provides tools for building modelling packages, with a focus on time series forecasting. This package allows package developers to extend *fable* with additional models, without needing to depend on the models supported by *fable*.
The R package *fabletools* provides tools for building modelling packages, with a focus on time series forecasting. This package allows package developers to extend *fable* with additional models, without needing to depend on the models supported by *fable*.

## Installation

You can install the **development** version from
[GitHub](https://github.com/tidyverts/fablelite)
[GitHub](https://github.com/tidyverts/fabletools)

```{r gh-installation, eval = FALSE}
# install.packages("devtools")
devtools::install_github("tidyverts/fablelite")
devtools::install_github("tidyverts/fabletools")
```
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@

<!-- README.md is generated from README.Rmd. Please edit that file -->

# fablelite
# fabletools

[![Travis build
status](https://travis-ci.org/tidyverts/fablelite.svg?branch=master)](https://travis-ci.org/tidyverts/fablelite)
status](https://travis-ci.org/tidyverts/fabletools.svg?branch=master)](https://travis-ci.org/tidyverts/fabletools)
[![AppVeyor Build
Status](https://ci.appveyor.com/api/projects/status/github/tidyverts/fablelite?branch=master&svg=true)](https://ci.appveyor.com/project/tidyverts/fablelite)
Status](https://ci.appveyor.com/api/projects/status/github/tidyverts/fabletools?branch=master&svg=true)](https://ci.appveyor.com/project/tidyverts/fabletools)
[![Code test
coverage](https://codecov.io/gh/tidyverts/fablelite/branch/master/graph/badge.svg)](https://codecov.io/gh/tidyverts/fablelite?branch=master)
coverage](https://codecov.io/gh/tidyverts/fabletools/branch/master/graph/badge.svg)](https://codecov.io/gh/tidyverts/fabletools?branch=master)
[![lifecycle](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://www.tidyverse.org/lifecycle/#experimental)
[![Licence](https://img.shields.io/badge/licence-GPL--3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0.en.html)

The R package *fablelite* provides tools for building modelling
The R package *fabletools* provides tools for building modelling
packages, with a focus on time series forecasting. This package allows
package developers to extend *fable* with additional models, without
needing to depend on the models supported by *fable*.

## Installation

You can install the **development** version from
[GitHub](https://github.com/tidyverts/fablelite)
[GitHub](https://github.com/tidyverts/fabletools)

``` r
# install.packages("devtools")
devtools::install_github("tidyverts/fablelite")
devtools::install_github("tidyverts/fabletools")
```
6 changes: 3 additions & 3 deletions _pkgdown.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
url: https://fablelite.tidyverts.org
url: https://fabletools.tidyverts.org

template:
params:
Expand Down Expand Up @@ -52,7 +52,7 @@ reference:
- percentile_score
- title: Methods
desc: >
The fablelite package facilitates the handling of key structures for these generics.
The fabletools package facilitates the handling of key structures for these generics.
contents:
- forecast
- model
Expand All @@ -69,7 +69,7 @@ reference:
- residuals.mdl_df
- title: Graphics
desc: >
Some `autoplot()` and `autolayer()` methods are defined for classes commonly used within fablelite.
Some `autoplot()` and `autolayer()` methods are defined for classes commonly used within fabletools.
contents:
- autoplot.tbl_ts
- autolayer.tbl_ts
Expand Down
2 changes: 1 addition & 1 deletion cran-comments.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ This is a joint submission with fable and feasts. These packages are
interdependent in their examples and functionality, so all packages will need
to be installed prior to checking the packages.

fablelite should be installed first, and then fable and feasts.
fabletools should be installed first, and then fable and feasts.

Unfortunately due to this dependency, the packages could not be tested using
win-builder. Instead these packages have been checked on Windows using AppVeyor.
Expand Down
File renamed without changes.
15 changes: 10 additions & 5 deletions man/fablelite-package.Rd → man/fabletools-package.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/features_by_pkg.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/features_by_tag.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/min_trace.Rd

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

4 changes: 2 additions & 2 deletions tests/testthat/test-distributions.R
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ test_that("Normal distribution", {
d*d,
"Multiplying forecast distributions is not supported"
) %>%
fablelite:::is_dist_unknown() %>%
fabletools:::is_dist_unknown() %>%
expect_true()

expect_length(rep(d, 10), 10)
Expand All @@ -40,7 +40,7 @@ test_that("Normal distribution", {
# d
# )

td <- fablelite:::update_fcdist(d, transformation = list(function(x) exp(x)))
td <- fabletools:::update_fcdist(d, transformation = list(function(x) exp(x)))

expect_equal(
hilo(d)[[1]] %>% mutate(.lower = exp(.lower), .upper = exp(.upper)),
Expand Down
2 changes: 1 addition & 1 deletion tests/testthat/test-transformations.R
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ test_transformation <- function(..., dt = simple_data){
resp <- mdl$response[[1]]
expect_equal(
dt[[expr_text(resp)]],
fablelite:::invert_transformation(trans)(trans(dt[[expr_text(resp)]]))
fabletools:::invert_transformation(trans)(trans(dt[[expr_text(resp)]]))
)
}

Expand Down
2 changes: 1 addition & 1 deletion tic.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,6 @@ if (Sys.getenv("BUILD_PKGDOWN") != "" && ci()$get_branch() == "master") {
prepare_call = remotes::install_github("r-lib/pkgbuild")
) %>%
add_step(step_build_pkgdown(run_dont_run = TRUE)) %>%
add_code_step(system('echo "fablelite.tidyverts.org" > docs/CNAME')) %>%
add_code_step(system('echo "fabletools.tidyverts.org" > docs/CNAME')) %>%
add_step(step_do_push_deploy(path = "docs"))
}

0 comments on commit 5f4753d

Please sign in to comment.