Package: iNZightTS Check: tests New result: ERROR Running ‘testthat.R’ [26s/26s] Running the tests in ‘tests/testthat.R’ failed. Complete output: > library(testthat) > library(iNZightTS) > > test_check("iNZightTS") Plot variable not specified, automatically selected `var = "Visitors"` Plot variable not specified, automatically selected `var = "Visitors"` Plot variable not specified, automatically selected `var = "Australia"` Plot variable not specified, automatically selected `var = "Australia"` Saving _problems/test_plots-7.R Plot variable not specified, automatically selected `var = "Australia"` Saving _problems/test_plots-13.R Plot variable not specified, automatically selected `var = "Australia"` Saving _problems/test_plots-17.R Decomp variable not specified, automatically selected `var = "Australia"` Plot variable not specified, automatically selected `var = "Australia"` Plot variable not specified, automatically selected `var = "Australia"` Plot variable not specified, automatically selected `var = "Japan"` Plot variable not specified, automatically selected `var = "Australia"` Predict variable not specified, automatically selected `var = "Australia"` Saving _problems/test_plots-40.R Saving _problems/test_plots-49.R Predict variable not specified, automatically selected `var = "Australia"` Saving _problems/test_plots-58.R Plot variable not specified, automatically selected `var = "Australia"` Saving _problems/test_plots-69.R Decomp variable not specified, automatically selected `var = "Australia"` Plot variable not specified, automatically selected `var = "Australia"` Plot variable not specified, automatically selected `var = "Australia"` Plot variable not specified, automatically selected `var = "Australia"` Predict variable not specified, automatically selected `var = "Australia"` Predict variable not specified, automatically selected `var = "Australia"` Predict variable not specified, automatically selected `var = "Australia"` Predict variable not specified, automatically selected `var = "Australia"` Predict variable not specified, automatically selected `var = "Australia"` Predict variable not specified, automatically selected `var = "Australia"` Summary variable not specified, automatically selected `var = Australia` Predict variable not specified, automatically selected `var = "Visitors"` Saving _problems/test_plots-160.R Predict variable not specified, automatically selected `var = "Australia"` Saving _problems/test_submodel-18.R Saving _problems/test_subset-6.R Decomp variable not specified, automatically selected `var = "Australia"` Decomp variable not specified, automatically selected `var = "Australia"` Decomp variable not specified, automatically selected `var = "Australia"` Plot variable not specified, automatically selected `var = "Australia"` Plot variable not specified, automatically selected `var = "Australia"` Predict variable not specified, automatically selected `var = "Australia"` Saving _problems/test_subset-37.R Saving _problems/test_subset-43.R Plot variable not specified, automatically selected `var = "Daily_Deaths"` Saving _problems/test_subset-55.R [ FAIL 14 | WARN 41 | SKIP 0 | PASS 68 ] ══ Failed tests ════════════════════════════════════════════════════════════════ ── Error ('test_plots.R:7:5'): Basic ts graph works ──────────────────────────── Error in `fabletools::autoplot(x, !!var, linewidth = 1, alpha = op)`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_s3_class(plot(t), "ggplot") at test_plots.R:7:5 2. │ └─testthat::quasi_label(enquo(object)) 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. ├─base::plot(t) 5. └─iNZightTS:::plot.inz_ts(t) 6. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 7. │ └─base::structure(., use.plotly = ggplotable(.)) 8. └─iNZightTS:::plot_inzightts_var(...) 9. ├─fabletools::autoplot(x, !!var, linewidth = 1, alpha = op) 10. └─ggplot2:::autoplot.default(x, !!var, linewidth = 1, alpha = op) 11. └─cli::cli_abort(...) 12. └─rlang::abort(...) ── Error ('test_plots.R:13:5'): Smoother can be disabled ─────────────────────── Error in `fabletools::autoplot(x, !!var, linewidth = 1, alpha = op)`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_s3_class(plot(t, smoother = FALSE), "ggplot") at test_plots.R:13:5 2. │ └─testthat::quasi_label(enquo(object)) 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. ├─base::plot(t, smoother = FALSE) 5. └─iNZightTS:::plot.inz_ts(t, smoother = FALSE) 6. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 7. │ └─base::structure(., use.plotly = ggplotable(.)) 8. └─iNZightTS:::plot_inzightts_var(...) 9. ├─fabletools::autoplot(x, !!var, linewidth = 1, alpha = op) 10. └─ggplot2:::autoplot.default(x, !!var, linewidth = 1, alpha = op) 11. └─cli::cli_abort(...) 12. └─rlang::abort(...) ── Error ('test_plots.R:17:5'): Data can be seasonally adjusted ──────────────── Error in `fabletools::autoplot(x, !!var, linewidth = 1, alpha = op)`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_s3_class(...) at test_plots.R:17:5 2. │ └─testthat::quasi_label(enquo(object)) 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. ├─base::plot(t, seasonal_adjustment = TRUE) 5. └─iNZightTS:::plot.inz_ts(t, seasonal_adjustment = TRUE) 6. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 7. │ └─base::structure(., use.plotly = ggplotable(.)) 8. └─iNZightTS:::plot_inzightts_var(...) 9. ├─fabletools::autoplot(x, !!var, linewidth = 1, alpha = op) 10. └─ggplot2:::autoplot.default(x, !!var, linewidth = 1, alpha = op) 11. └─cli::cli_abort(...) 12. └─rlang::abort(...) ── Error ('test_plots.R:40:5'): Forecast is fine ─────────────────────────────── Error in `fabletools::autoplot(dplyr::filter(dplyr::select(x, -.var), .model != "Raw data"), .mean, linetype = ifelse(n_keys > 3, "dashed", "solid"))`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_s3_class(plot(predict(t, h = 8)), "ggplot") at test_plots.R:40:5 2. │ └─testthat::quasi_label(enquo(object)) 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. ├─base::plot(predict(t, h = 8)) 5. └─iNZightTS:::plot.inz_frct(predict(t, h = 8)) 6. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 7. │ └─base::structure(., use.plotly = ggplotable(.)) 8. └─iNZightTS:::plot_forecast_var(...) 9. ├─fabletools::autoplot(...) 10. └─ggplot2:::autoplot.default(...) 11. └─cli::cli_abort(...) 12. └─rlang::abort(...) ── Error ('test_plots.R:49:5'): Multi series graph works ─────────────────────── Error in `fabletools::autoplot(x, !!var, linewidth = 1, alpha = op)`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_s3_class(plot(tm, var_name), "patchwork") at test_plots.R:49:5 2. │ └─testthat::quasi_label(enquo(object)) 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. ├─base::plot(tm, var_name) 5. └─iNZightTS:::plot.inz_ts(tm, var_name) 6. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 7. │ └─base::structure(., use.plotly = ggplotable(.)) 8. └─base::lapply(...) 9. └─iNZightTS (local) FUN(X[[i]], ...) 10. └─iNZightTS:::plot_inzightts_var(...) 11. ├─fabletools::autoplot(x, !!var, linewidth = 1, alpha = op) 12. └─ggplot2:::autoplot.default(x, !!var, linewidth = 1, alpha = op) 13. └─cli::cli_abort(...) 14. └─rlang::abort(...) ── Error ('test_plots.R:58:5'): Annual data forecast is fine ─────────────────── Error in `fabletools::autoplot(dplyr::filter(dplyr::select(x, -.var), .model != "Raw data"), .mean, linetype = ifelse(n_keys > 3, "dashed", "solid"))`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_s3_class(plot(predict(t)), "ggplot") at test_plots.R:58:5 2. │ └─testthat::quasi_label(enquo(object)) 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. ├─base::plot(predict(t)) 5. └─iNZightTS:::plot.inz_frct(predict(t)) 6. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 7. │ └─base::structure(., use.plotly = ggplotable(.)) 8. └─iNZightTS:::plot_forecast_var(...) 9. ├─fabletools::autoplot(...) 10. └─ggplot2:::autoplot.default(...) 11. └─cli::cli_abort(...) 12. └─rlang::abort(...) ── Error ('test_plots.R:69:5'): Check raw-plot configuration ─────────────────── Error in `fabletools::autoplot(x, !!var, linewidth = 1, alpha = op)`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_s3_class(plot(t, xlim = c(NA, NA)), "ggplot") at test_plots.R:69:5 2. │ └─testthat::quasi_label(enquo(object)) 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. ├─base::plot(t, xlim = c(NA, NA)) 5. └─iNZightTS:::plot.inz_ts(t, xlim = c(NA, NA)) 6. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 7. │ └─base::structure(., use.plotly = ggplotable(.)) 8. └─iNZightTS:::plot_inzightts_var(...) 9. ├─fabletools::autoplot(x, !!var, linewidth = 1, alpha = op) 10. └─ggplot2:::autoplot.default(x, !!var, linewidth = 1, alpha = op) 11. └─cli::cli_abort(...) 12. └─rlang::abort(...) ── Error ('test_plots.R:160:5'): Check forecasting configuration ─────────────── Error in `fabletools::autoplot(dplyr::filter(dplyr::select(x, -.var), .model != "Raw data"), .mean, linetype = ifelse(n_keys > 3, "dashed", "solid"))`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_s3_class(...) at test_plots.R:160:5 2. │ └─testthat::quasi_label(enquo(object)) 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. ├─base::plot(predict(y2, pred_model = fable::ARIMA)) 5. └─iNZightTS:::plot.inz_frct(predict(y2, pred_model = fable::ARIMA)) 6. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 7. │ └─base::structure(., use.plotly = ggplotable(.)) 8. └─iNZightTS:::plot_forecast_var(...) 9. ├─fabletools::autoplot(...) 10. └─ggplot2:::autoplot.default(...) 11. └─cli::cli_abort(...) 12. └─rlang::abort(...) ── Error ('test_submodel.R:18:5'): Forecasts uses specified region ───────────── Error in `fabletools::autoplot(dplyr::filter(dplyr::select(x, -.var), .model != "Raw data"), .mean, linetype = ifelse(n_keys > 3, "dashed", "solid"))`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─base::plot(predict(x, h = "2 years")) at test_submodel.R:18:5 2. └─iNZightTS:::plot.inz_frct(predict(x, h = "2 years")) 3. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 4. │ └─base::structure(., use.plotly = ggplotable(.)) 5. └─iNZightTS:::plot_forecast_var(...) 6. ├─fabletools::autoplot(...) 7. └─ggplot2:::autoplot.default(...) 8. └─cli::cli_abort(...) 9. └─rlang::abort(...) ── Error ('test_submodel.R:27:5'): Decomposition uses sub-portion of the plots (multi) ── Error in `fabletools::autoplot(dplyr::filter(dplyr::select(x, -.var), .model != "Raw data"), .mean, linetype = ifelse(n_keys > 3, "dashed", "solid"))`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_silent(plot(predict(x, names(x[-1])))) at test_submodel.R:27:5 2. │ └─testthat:::quasi_capture(enquo(object), NULL, evaluate_promise) 3. │ ├─testthat (local) .capture(...) 4. │ │ ├─withr::with_output_sink(...) 5. │ │ │ └─base::force(code) 6. │ │ ├─base::withCallingHandlers(...) 7. │ │ └─base::withVisible(code) 8. │ └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo)) 9. ├─base::plot(predict(x, names(x[-1]))) 10. └─iNZightTS:::plot.inz_frct(predict(x, names(x[-1]))) 11. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 12. │ └─base::structure(., use.plotly = ggplotable(.)) 13. └─base::lapply(...) 14. └─iNZightTS (local) FUN(X[[i]], ...) 15. └─iNZightTS:::plot_forecast_var(x, sym(y_var), xlab, ylab[i], "") 16. ├─fabletools::autoplot(...) 17. └─ggplot2:::autoplot.default(...) 18. └─cli::cli_abort(...) 19. └─rlang::abort(...) ── Error ('test_subset.R:6:5'): Subset of time series can be viewed ──────────── Error in `fabletools::autoplot(x, !!var, linewidth = 1, alpha = op)`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_message(...) at test_subset.R:6:5 2. │ └─testthat:::expect_condition_matching_(...) 3. │ └─testthat:::quasi_capture(...) 4. │ ├─testthat (local) .capture(...) 5. │ │ └─base::withCallingHandlers(...) 6. │ └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo)) 7. ├─base::plot(t, xlim = as.Date(c("2000-01-01", "2011-01-01"))) 8. └─iNZightTS:::plot.inz_ts(t, xlim = as.Date(c("2000-01-01", "2011-01-01"))) 9. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 10. │ └─base::structure(., use.plotly = ggplotable(.)) 11. └─iNZightTS:::plot_inzightts_var(...) 12. ├─fabletools::autoplot(x, !!var, linewidth = 1, alpha = op) 13. └─ggplot2:::autoplot.default(x, !!var, linewidth = 1, alpha = op) 14. └─cli::cli_abort(...) 15. └─rlang::abort(...) ── Error ('test_subset.R:37:5'): Subset of forecast plot ─────────────────────── Error in `fabletools::autoplot(dplyr::filter(dplyr::select(x, -.var), .model != "Raw data"), .mean, linetype = ifelse(n_keys > 3, "dashed", "solid"))`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_s3_class(...) at test_subset.R:37:5 2. │ └─testthat::quasi_label(enquo(object)) 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. ├─base::plot(predict(t, h = 8, xlim = c(2000, 2010))) 5. └─iNZightTS:::plot.inz_frct(predict(t, h = 8, xlim = c(2000, 2010))) 6. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 7. │ └─base::structure(., use.plotly = ggplotable(.)) 8. └─iNZightTS:::plot_forecast_var(...) 9. ├─fabletools::autoplot(...) 10. └─ggplot2:::autoplot.default(...) 11. └─cli::cli_abort(...) 12. └─rlang::abort(...) ── Error ('test_subset.R:43:5'): Subset of multi series graph works ──────────── Error in `fabletools::autoplot(x, !!var, linewidth = 1, alpha = op)`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─base::plot(tm, names(tm)[-1], xlim = c(2000, 2011)) at test_subset.R:43:5 2. └─iNZightTS:::plot.inz_ts(tm, names(tm)[-1], xlim = c(2000, 2011)) 3. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 4. │ └─base::structure(., use.plotly = ggplotable(.)) 5. └─base::lapply(...) 6. └─iNZightTS (local) FUN(X[[i]], ...) 7. └─iNZightTS:::plot_inzightts_var(...) 8. ├─fabletools::autoplot(x, !!var, linewidth = 1, alpha = op) 9. └─ggplot2:::autoplot.default(x, !!var, linewidth = 1, alpha = op) 10. └─cli::cli_abort(...) 11. └─rlang::abort(...) ── Error ('test_subset.R:55:5'): Modelling limits are OK ─────────────────────── Error in `fabletools::autoplot(x, !!var, linewidth = 1, alpha = op)`: Objects of class are not supported by autoplot. i Have you loaded the required package? Backtrace: ▆ 1. ├─testthat::expect_s3_class(plot(ct), "ggplot") at test_subset.R:55:5 2. │ └─testthat::quasi_label(enquo(object)) 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. ├─base::plot(ct) 5. └─iNZightTS:::plot.inz_ts(ct) 6. ├─(function(.) structure(., use.plotly = ggplotable(.)))(...) 7. │ └─base::structure(., use.plotly = ggplotable(.)) 8. └─iNZightTS:::plot_inzightts_var(...) 9. ├─fabletools::autoplot(x, !!var, linewidth = 1, alpha = op) 10. └─ggplot2:::autoplot.default(x, !!var, linewidth = 1, alpha = op) 11. └─cli::cli_abort(...) 12. └─rlang::abort(...) [ FAIL 14 | WARN 41 | SKIP 0 | PASS 68 ] Error: ! Test failures. Execution halted Package: vital Check: examples New result: ERROR Running examples in ‘vital-Ex.R’ failed The error most likely occurred in: > base::assign(".ptime", proc.time(), pos = "CheckExEnv") > ### Name: FDM > ### Title: Functional data model > ### Aliases: FDM report.FDM > > ### ** Examples > > hu <- norway_mortality |> + dplyr::filter(Sex == "Female", Year > 2010) |> + smooth_mortality(Mortality) |> + model(hyndman_ullah = FDM(log(.smooth))) > report(hu) Series: .smooth Model: FDM Transformation: log(.smooth) Basis functions # A tibble: 111 × 8 Age mean phi1 phi2 phi3 phi4 phi5 phi6 1 0 -6.27 -0.0470 0.153 0.107 0.220 0.00196 -0.299 2 1 -8.51 0.167 0.107 0.295 0.00735 -0.410 -0.269 3 2 -9.00 0.170 0.0341 0.295 -0.00474 -0.314 -0.195 4 3 -9.22 0.155 -0.0284 0.298 -0.0733 -0.121 -0.0204 5 4 -9.33 0.119 -0.0878 0.298 -0.125 0.0290 0.103 # ℹ 106 more rows Coefficients # A tsibble: 13 x 8 [1Y] Year mean beta1 beta2 beta3 beta4 beta5 beta6 1 2011 1 2.06 0.297 -0.562 0.0844 0.164 0.119 2 2012 1 0.356 0.135 0.943 0.543 0.314 -0.134 3 2013 1 0.126 0.662 0.334 0.437 -0.0629 0.0955 4 2014 1 -0.892 0.729 -0.246 0.175 0.258 0.0968 5 2015 1 -0.652 0.678 -0.418 0.128 -0.410 0.0857 # ℹ 8 more rows Time series models beta1 : ARIMA(0,0,0) beta2 : ARIMA(1,0,0) beta3 : ARIMA(0,0,0) beta4 : ARIMA(0,0,0) beta5 : ARIMA(0,0,0) beta6 : ARIMA(0,0,0) Variance explained 34.57 + 23.46 + 18.78 + 13.54 + 5.59 + 1.5 = 97.45% > autoplot(hu) Error in `fabletools::autoplot()`: ! Objects of class are not supported by autoplot. ℹ Have you loaded the required package? Backtrace: ▆ 1. ├─ggplot2::autoplot(hu) 2. └─vital:::autoplot.mdl_vtl_df(hu) 3. ├─ggplot2::autoplot(object, age = agevar, ...) 4. └─vital:::autoplot.FDM(object, age = agevar, ...) 5. └─vital:::age_plot(obj_x, meanvar, keys) 6. ├─fabletools::autoplot(object_ts, !!sym(.var)) 7. └─ggplot2:::autoplot.default(object_ts, !!sym(.var)) 8. └─cli::cli_abort(...) 9. └─rlang::abort(...) Execution halted