diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1214f736..6a57a8a4 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -2,7 +2,7 @@ # R specific hooks: https://github.com/lorenzwalthert/precommit repos: - repo: https://github.com/lorenzwalthert/precommit - rev: v0.3.2.9027 + rev: v0.4.3.9003 hooks: - id: style-files args: [--style_pkg=styler.mlr, --style_fun=mlr_style] @@ -33,7 +33,7 @@ repos: # uncomment after https://github.com/lorenzwalthert/precommit/issues/352 # - id: deps-in-desc - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.5.0 + rev: v5.0.0 hooks: - id: check-added-large-files args: ["--maxkb=1000"] diff --git a/DESCRIPTION b/DESCRIPTION index 4c387811..4f544149 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: mlr3spatiotempcv Title: Spatiotemporal Resampling Methods for 'mlr3' -Version: 2.3.1 +Version: 2.3.2 Authors@R: c( person("Patrick", "Schratz", , "patrick.schratz@gmail.com", role = c("aut", "cre"), comment = c(ORCID = "0000-0003-0748-6624")), @@ -11,10 +11,11 @@ Authors@R: c( person("Michel", "Lang", , "michellang@gmail.com", role = "ctb", comment = c(ORCID = "0000-0001-9754-0393")) ) -Description: Extends the mlr3 ML framework with spatio-temporal resampling - methods to account for the presence of spatiotemporal autocorrelation - (STAC) in predictor variables. STAC may cause highly biased - performance estimates in cross-validation if ignored. +Description: Extends the mlr3 machine learning framework with + spatio-temporal resampling methods to account for the presence of + spatiotemporal autocorrelation (STAC) in predictor variables. STAC may + cause highly biased performance estimates in cross-validation if + ignored. A JSS article is available at . License: LGPL-3 URL: https://mlr3spatiotempcv.mlr-org.com/, https://github.com/mlr-org/mlr3spatiotempcv, @@ -64,7 +65,7 @@ Encoding: UTF-8 LazyData: true NeedsCompilation: no Roxygen: list(markdown = TRUE, r6 = TRUE) -RoxygenNote: 7.3.0 +RoxygenNote: 7.3.2 Collate: 'aaa.R' 'ResamplingRepeatedSpCVBlock.R' diff --git a/NEWS.md b/NEWS.md index 96b9e375..1a3c068d 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,5 +1,10 @@ +# mlr3spatiotempcv 2.3.2 + +- Internal changes only. + + # mlr3spatiotempcv 2.3.1 - Add support for new {paradox} version (#234) diff --git a/R/ResamplingRepeatedSpCVBlock.R b/R/ResamplingRepeatedSpCVBlock.R index bb756a60..0cc45a82 100644 --- a/R/ResamplingRepeatedSpCVBlock.R +++ b/R/ResamplingRepeatedSpCVBlock.R @@ -102,7 +102,7 @@ ResamplingRepeatedSpCVBlock = R6Class("ResamplingRepeatedSpCVBlock", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { diff --git a/R/ResamplingRepeatedSpCVCoords.R b/R/ResamplingRepeatedSpCVCoords.R index bf66e6d2..39b8debb 100644 --- a/R/ResamplingRepeatedSpCVCoords.R +++ b/R/ResamplingRepeatedSpCVCoords.R @@ -73,7 +73,7 @@ ResamplingRepeatedSpCVCoords = R6Class("ResamplingRepeatedSpCVCoords", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { diff --git a/R/ResamplingRepeatedSpCVDisc.R b/R/ResamplingRepeatedSpCVDisc.R index 9fe40a2c..d161a2ca 100644 --- a/R/ResamplingRepeatedSpCVDisc.R +++ b/R/ResamplingRepeatedSpCVDisc.R @@ -83,7 +83,7 @@ ResamplingRepeatedSpCVDisc = R6Class("ResamplingRepeatedSpCVDisc", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { diff --git a/R/ResamplingRepeatedSpCVEnv.R b/R/ResamplingRepeatedSpCVEnv.R index c6e7182d..c4931212 100644 --- a/R/ResamplingRepeatedSpCVEnv.R +++ b/R/ResamplingRepeatedSpCVEnv.R @@ -73,7 +73,7 @@ ResamplingRepeatedSpCVEnv = R6Class("ResamplingRepeatedSpCVEnv", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { diff --git a/R/ResamplingRepeatedSpCVTiles.R b/R/ResamplingRepeatedSpCVTiles.R index a8614e8e..49120b93 100644 --- a/R/ResamplingRepeatedSpCVTiles.R +++ b/R/ResamplingRepeatedSpCVTiles.R @@ -100,7 +100,7 @@ ResamplingRepeatedSpCVTiles = R6Class("ResamplingRepeatedSpCVTiles", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { diff --git a/R/ResamplingRepeatedSpCVknndm.R b/R/ResamplingRepeatedSpCVknndm.R index 2be39d99..2c933d8f 100644 --- a/R/ResamplingRepeatedSpCVknndm.R +++ b/R/ResamplingRepeatedSpCVknndm.R @@ -96,7 +96,7 @@ ResamplingRepeatedSpCVKnndm = R6Class("ResamplingRepeatedSpCVKnndm", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { diff --git a/R/ResamplingRepeatedSptCVCstf.R b/R/ResamplingRepeatedSptCVCstf.R index e2dcd134..714361d3 100644 --- a/R/ResamplingRepeatedSptCVCstf.R +++ b/R/ResamplingRepeatedSptCVCstf.R @@ -74,7 +74,7 @@ ResamplingRepeatedSptCVCstf = R6Class("ResamplingRepeatedSptCVCstf", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { task = assert_task(task) diff --git a/R/ResamplingSpCVBlock.R b/R/ResamplingSpCVBlock.R index 05977510..02f39d8d 100644 --- a/R/ResamplingSpCVBlock.R +++ b/R/ResamplingSpCVBlock.R @@ -73,7 +73,7 @@ ResamplingSpCVBlock = R6Class("ResamplingSpCVBlock", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { mlr3misc::require_namespaces(c("blockCV", "sf")) diff --git a/R/ResamplingSpCVBuffer.R b/R/ResamplingSpCVBuffer.R index d28b1aed..ec588afc 100644 --- a/R/ResamplingSpCVBuffer.R +++ b/R/ResamplingSpCVBuffer.R @@ -54,7 +54,7 @@ ResamplingSpCVBuffer = R6Class("ResamplingSpCVBuffer", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { diff --git a/R/ResamplingSpCVCoords.R b/R/ResamplingSpCVCoords.R index acf115c7..a029a881 100644 --- a/R/ResamplingSpCVCoords.R +++ b/R/ResamplingSpCVCoords.R @@ -48,7 +48,7 @@ ResamplingSpCVCoords = R6Class("ResamplingSpCVCoords", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { diff --git a/R/ResamplingSpCVDisc.R b/R/ResamplingSpCVDisc.R index 64e372f9..2dfa810f 100644 --- a/R/ResamplingSpCVDisc.R +++ b/R/ResamplingSpCVDisc.R @@ -58,7 +58,7 @@ ResamplingSpCVDisc = R6Class("ResamplingSpCVDisc", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { diff --git a/R/ResamplingSpCVEnv.R b/R/ResamplingSpCVEnv.R index 0055b12e..7cd282f4 100644 --- a/R/ResamplingSpCVEnv.R +++ b/R/ResamplingSpCVEnv.R @@ -53,7 +53,7 @@ ResamplingSpCVEnv = R6Class("ResamplingSpCVEnv", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { diff --git a/R/ResamplingSpCVKnndm.R b/R/ResamplingSpCVKnndm.R index d232ac98..208c1d98 100644 --- a/R/ResamplingSpCVKnndm.R +++ b/R/ResamplingSpCVKnndm.R @@ -74,7 +74,7 @@ ResamplingSpCVKnndm = R6Class("ResamplingSpCVKnndm", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { task = assert_task(task) diff --git a/R/ResamplingSpCVTiles.R b/R/ResamplingSpCVTiles.R index 2bcda069..93c36708 100644 --- a/R/ResamplingSpCVTiles.R +++ b/R/ResamplingSpCVTiles.R @@ -57,7 +57,7 @@ ResamplingSpCVTiles = R6Class("ResamplingSpCVTiles", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { diff --git a/R/ResamplingSptCVCstf.R b/R/ResamplingSptCVCstf.R index c2a49dfb..5ff69246 100644 --- a/R/ResamplingSptCVCstf.R +++ b/R/ResamplingSptCVCstf.R @@ -52,7 +52,7 @@ ResamplingSptCVCstf = R6Class("ResamplingSptCVCstf", #' @description #' Materializes fixed training and test splits for a given task. - #' @param task [Task]\cr + #' @param task [mlr3::Task]\cr #' A task to instantiate. instantiate = function(task) { task = assert_task(task) diff --git a/R/TaskClassifST.R b/R/TaskClassifST.R index fb6e4631..dc0ace47 100644 --- a/R/TaskClassifST.R +++ b/R/TaskClassifST.R @@ -1,6 +1,6 @@ #' @title Create a Spatiotemporal Classification Task #' -#' @description This task specializes [Task] and [TaskSupervised] for +#' @description This task specializes [mlr3::Task] and [mlr3::TaskSupervised] for #' spatiotemporal classification problems. The target column is assumed to be a #' factor. The `task_type` is set to `"classif"` and `"spatiotemporal"`. #' diff --git a/R/TaskRegrST.R b/R/TaskRegrST.R index 3980bde1..e1bc7f79 100644 --- a/R/TaskRegrST.R +++ b/R/TaskRegrST.R @@ -1,7 +1,7 @@ #' @title Create a Spatiotemporal Regression Task #' #' @description -#' This task specializes [Task] and [TaskSupervised] for spatiotemporal +#' This task specializes [mlr3::Task] and [mlr3::TaskSupervised] for spatiotemporal #' classification problems. #' #' A spatial example task is available via `tsk("ecuador")`, a spatiotemporal diff --git a/R/Task_classif_diplodia.R b/R/Task_classif_diplodia.R index 6f427d79..554accfa 100644 --- a/R/Task_classif_diplodia.R +++ b/R/Task_classif_diplodia.R @@ -3,7 +3,7 @@ #' @docType data #' @usage data(diplodia) #' @name mlr_tasks_diplodia -#' @format [R6::R6Class] inheriting from [TaskClassif]. +#' @format [R6::R6Class] inheriting from [mlr3::TaskClassif]. #' #' @section Usage: #' ``` diff --git a/R/Task_classif_ecuador.R b/R/Task_classif_ecuador.R index e3250ea1..0f56e3a1 100644 --- a/R/Task_classif_ecuador.R +++ b/R/Task_classif_ecuador.R @@ -3,7 +3,7 @@ #' @docType data #' @usage data(ecuador) #' @name mlr_tasks_ecuador -#' @format [R6::R6Class] inheriting from [TaskClassif]. +#' @format [R6::R6Class] inheriting from [mlr3::TaskClassif]. #' #' @section Usage: #' ``` diff --git a/R/Task_regr_cookfarm_profiles.R b/R/Task_regr_cookfarm_profiles.R index a91e4364..2c09fed7 100644 --- a/R/Task_regr_cookfarm_profiles.R +++ b/R/Task_regr_cookfarm_profiles.R @@ -3,7 +3,7 @@ #' @docType data #' @usage data(cookfarm_mlr3) #' @name mlr_tasks_cookfarm_mlr3 -#' @format [R6::R6Class] inheriting from [TaskRegr]. +#' @format [R6::R6Class] inheriting from [mlr3::TaskRegr]. #' #' @section Usage: #' ``` diff --git a/R/as_task_classif_st.R b/R/as_task_classif_st.R index c9848eb0..a16d49f5 100644 --- a/R/as_task_classif_st.R +++ b/R/as_task_classif_st.R @@ -5,10 +5,10 @@ #' This is a S3 generic for the following objects: #' #' 1. [TaskClassifST]: Ensure the identity. -#' 1. [data.frame()] and [DataBackend]: Provides an alternative to the +#' 1. [data.frame()] and [mlr3::DataBackend]: Provides an alternative to the #' constructor of [TaskClassifST]. #' 1. [sf::sf]: Extracts spatial meta data before construction. -#' 1. [TaskRegr]: Calls [convert_task()]. +#' 1. [mlr3::TaskRegr]: Calls [mlr3::convert_task()]. #' #' @param x (any)\cr #' Object to convert. diff --git a/R/as_task_regr_st.R b/R/as_task_regr_st.R index 1ab4305d..1cd4f2f0 100644 --- a/R/as_task_regr_st.R +++ b/R/as_task_regr_st.R @@ -6,10 +6,10 @@ #' This is a S3 generic, specialized for at least the following objects: #' #' 1. [TaskRegrST]: Ensure the identity. -#' 1. [data.frame()] and [DataBackend]: Provides an alternative to the +#' 1. [data.frame()] and [mlr3::DataBackend]: Provides an alternative to the #' constructor of [TaskRegrST]. #' 1. [sf::sf]: Extracts spatial meta data before construction. -#' 1. [TaskClassif]: Calls [convert_task()]. +#' 1. [mlr3::TaskClassif]: Calls [mlr3::convert_task()]. #' #' @param x (any)\cr #' Object to convert. diff --git a/R/autoplot.R b/R/autoplot.R index c4f35480..52734d92 100644 --- a/R/autoplot.R +++ b/R/autoplot.R @@ -48,7 +48,7 @@ #' When no single fold is selected, the [ggsci::scale_color_ucscgb()] palette #' is used to display all partitions. #' If you want to change the colors, call ` + ()`. -#' @return [ggplot()] or list of ggplot2 objects. +#' @return [ggplot2::ggplot()] or list of ggplot2 objects. #' @name autoplot.ResamplingSpCVBlock #' @seealso #' - mlr3book chapter on ["Spatial Analysis"](https://mlr3book.mlr-org.com/chapters/chapter13/beyond_regression_and_classification.html#sec-spatiotemporal) @@ -874,11 +874,11 @@ plot.ResamplingRepeatedSpCVKnndm = function(x, ...) { #' #' @name autoplot.ResamplingCV #' @param object `[Resampling]`\cr -#' mlr3 spatial resampling object of class [ResamplingCV] or -#' [ResamplingRepeatedCV]. +#' mlr3 spatial resampling object of class [mlr3::ResamplingCV] or +#' [mlr3::ResamplingRepeatedCV]. #' @param x `[Resampling]`\cr -#' mlr3 spatial resampling object of class [ResamplingCV] or -#' [ResamplingRepeatedCV]. +#' mlr3 spatial resampling object of class [mlr3::ResamplingCV] or +#' [mlr3::ResamplingRepeatedCV]. #' @inheritParams autoplot.ResamplingSpCVBlock #' @export #' @seealso @@ -960,9 +960,9 @@ autoplot.ResamplingRepeatedCV = function( # nolint #' #' @name autoplot.ResamplingCustomCV #' @param object `[Resampling]`\cr -#' mlr3 spatial resampling object of class [ResamplingCustomCV]. +#' mlr3 spatial resampling object of class [mlr3::ResamplingCustomCV]. #' @param x `[Resampling]`\cr -#' mlr3 spatial resampling object of class [ResamplingCustomCV]. +#' mlr3 spatial resampling object of class [mlr3::ResamplingCustomCV]. #' @inheritParams autoplot.ResamplingSpCVBlock #' @export #' @seealso diff --git a/README.md b/README.md index f0c0162f..5502058d 100644 --- a/README.md +++ b/README.md @@ -57,7 +57,7 @@ This list does not claim to be comprehensive. | Name | Language | Resources | | ------------- | -------- | ----------------------------------------------------------------------------------------------------------------------------- | | blockCV | R | [CRAN](https://cran.r-project.org/package=blockCV) | -| CAST | R | [Paper](https://www.sciencedirect.com/science/article/pii/S1364815217310976), [CRAN](https://cran.r-project.org/package=CAST) | +| CAST | R | [Paper](https://doi.org/10.1016/j.envsoft.2017.12.001), [CRAN](https://cran.r-project.org/package=CAST) | | ENMeval | R | [CRAN](https://cran.r-project.org/package=ENMeval) | | spatialsample | R | [CRAN](https://cran.r-project.org/package=spatialsample) | | sperrorest | R | [CRAN](https://cran.r-project.org/package=sperrorest) | diff --git a/cran-comments.md b/cran-comments.md index 82508943..459240f7 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,66 +1,58 @@ -mlr3spatiotempcv 2.3.1 +mlr3spatiotempcv 2.3.2 + +The DOI in the CITATION is for a new JSS publication that will be registered after publication on CRAN. ## Cran Repository Policy -- [x] Reviewed CRP last edited 2024-04-04. +- [x] Reviewed CRP last edited 2024-08-27. -See changes at https://github.com/eddelbuettel/crp/compare/master@%7B2023-08-15%7D...master@%7B2024-04-04%7D +See changes at https://github.com/eddelbuettel/crp/compare/master@%7B2024-04-04%7D...master@%7B2024-08-27%7D ## R CMD check results -- [x] Checked locally, R 4.3.3 -- [x] Checked on CI system, R 4.3.3 +- [x] Checked locally, R 4.4.2 +- [x] Checked on CI system, R 4.4.2 - [x] Checked on win-builder, R devel Check the boxes above after successful execution and remove this line. Then run `fledge::release()`. ## Current CRAN check results -- [x] Checked on 2024-04-16, problems found: https://cran.r-project.org/web/checks/check_results_mlr3spatiotempcv.html -- [x] ERROR: r-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc, r-patched-linux-x86_64, r-release-linux-x86_64 - Running examples in ‘mlr3spatiotempcv-Ex.R’ failed - The error most likely occurred in: - - > base::assign(".ptime", proc.time(), pos = "CheckExEnv") - > ### Name: mlr_resamplings_repeated_spcv_knndm - > ### Title: (CAST) Repeated K-fold Nearest Neighbour Distance Matching - > ### Aliases: mlr_resamplings_repeated_spcv_knndm - > ### ResamplingRepeatedSpCVKnndm - > - > ### ** Examples - > - > library(mlr3) - > library(mlr3spatial) - - Attaching package: ‘mlr3spatial’ - - The following objects are masked from ‘package:mlr3spatiotempcv’: - - TaskClassifST, TaskRegrST, as_task_classif_st, - as_task_classif_st.DataBackend, as_task_classif_st.TaskClassifST, - as_task_classif_st.data.frame, as_task_classif_st.sf, - as_task_regr_st, as_task_regr_st.DataBackend, - as_task_regr_st.TaskClassifST, as_task_regr_st.TaskRegrST, - as_task_regr_st.data.frame, as_task_regr_st.sf - - > set.seed(42) - > simarea = list(matrix(c(0, 0, 0, 100, 100, 100, 100, 0, 0, 0), ncol = 2, byrow = TRUE)) - > simarea = sf::st_polygon(simarea) - > train_points = sf::st_sample(simarea, 1000, type = "random") - > train_points = sf::st_as_sf(train_points) - > train_points$target = as.factor(sample(c("TRUE", "FALSE"), 1000, replace = TRUE)) - > pred_points = sf::st_sample(simarea, 1000, type = "regular") - > - > task = mlr3spatial::as_task_classif_st(sf::st_as_sf(train_points), "target", positive = "TRUE") - > - > cv_knndm = rsmp("repeated_spcv_knndm", ppoints = pred_points, repeats = 2) - > cv_knndm$instantiate(task) - Error in CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, : - unused argument (ppoints = self$param_set$values$ppoints) - Calls: ... .__ResamplingRepeatedSpCVKnndm__.sample -> map -> lapply -> FUN - Execution halted +- [x] Checked on 2024-11-27, problems found: https://cran.r-project.org/web/checks/check_results_mlr3spatiotempcv.html +- [x] NOTE: r-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc, r-devel-windows-x86_64 + Found the following Rd file(s) with Rd \link{} targets missing package + anchors: + TaskClassifST.Rd: Task, TaskSupervised, DataBackend, + DataBackendDataTable, convert_task + TaskRegrST.Rd: Task, TaskSupervised, DataBackend, + DataBackendDataTable, convert_task + as_task_classif_st.Rd: DataBackend, TaskRegr, convert_task + as_task_regr_st.Rd: DataBackend, TaskClassif, convert_task + autoplot.ResamplingCV.Rd: ResamplingCV, ResamplingRepeatedCV + autoplot.ResamplingCustomCV.Rd: ResamplingCustomCV + autoplot.ResamplingSpCVBlock.Rd: ggplot + mlr_resamplings_repeated_spcv_block.Rd: Task + mlr_resamplings_repeated_spcv_coords.Rd: Task + mlr_resamplings_repeated_spcv_disc.Rd: Task + mlr_resamplings_repeated_spcv_env.Rd: Task + mlr_resamplings_repeated_spcv_knndm.Rd: Task + mlr_resamplings_repeated_spcv_tiles.Rd: Task + mlr_resamplings_repeated_sptcv_cstf.Rd: Task + mlr_resamplings_spcv_block.Rd: Task + mlr_resamplings_spcv_buffer.Rd: Task + mlr_resamplings_spcv_coords.Rd: Task + mlr_resamplings_spcv_disc.Rd: Task + mlr_resamplings_spcv_env.Rd: Task + mlr_resamplings_spcv_knndm.Rd: Task + mlr_resamplings_spcv_tiles.Rd: Task + mlr_resamplings_sptcv_cstf.Rd: Task + mlr_tasks_cookfarm_mlr3.Rd: TaskRegr, Task, mlr_tasks + mlr_tasks_diplodia.Rd: TaskClassif, Task, mlr_tasks + mlr_tasks_ecuador.Rd: TaskClassif, Task, mlr_tasks + Please provide package anchors for all Rd \link{} targets not in the + package itself and the base packages. - [x] ERROR: r-devel-linux-x86_64-debian-clang - Running ‘testthat.R’ [118s/81s] + Running ‘testthat.R’ [103s/54s] Running the tests in ‘tests/testthat.R’ failed. Complete output: > if (requireNamespace("testthat", quietly = TRUE)) { @@ -71,10 +63,10 @@ Check the boxes above after successful execution and remove this line. Then run + } Loading required package: mlr3 Starting 2 test processes - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] - ══ Skipped tests (23) ══════════════════════════════════════════════════════════ - • On CRAN (18): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', + ══ Skipped tests (24) ══════════════════════════════════════════════════════════ + • On CRAN (19): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', 'test-1-autoplot.R:98:3', 'test-1-autoplot.R:130:3', 'test-1-autoplot.R:157:3', 'test-1-autoplot.R:189:3', 'test-1-autoplot.R:224:3', 'test-1-autoplot.R:257:3', @@ -82,123 +74,36 @@ Check the boxes above after successful execution and remove this line. Then run 'test-1-autoplot.R:343:3', 'test-1-autoplot.R:377:3', 'test-2-autoplot.R:129:3', 'test-2-autoplot.R:182:3', 'test-2-autoplot.R:204:3', 'test-2-autoplot.R:246:3', - 'test-2-autoplot.R:300:3', 'test-autoplot_buffer.R:19:3' + 'test-2-autoplot.R:300:3', 'test-2-autoplot.R:352:3', + 'test-autoplot_buffer.R:19:3' • On Linux (2): 'test-2-autoplot.R:8:3', 'test-2-autoplot.R:54:3' • empty test (1): 'test-helper-DataBackend.R:1:1' • raster cannot be loaded (1): 'test-mlr3pipelines-graph-integration.R:4:3' • skmeans cannot be loaded (1): 'test-mlr_sptcv_generic.R:70:3' ══ Failed tests ════════════════════════════════════════════════════════════════ - ── Error ('test-2-autoplot.R:331:3'): plot() works for 'spcv_knndm' ──────────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) + ── Error ('test-TaskClassifST.R:16:3'): Supplying a non-spatio temporal task gives descriptive error message ── + Error: Element with key 'boston_housing' not found in DictionaryTask! Backtrace: ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-2-autoplot.R:331:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:21:3'): folds can be printed ───── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:21:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:31:3'): reps can be printed ────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:31:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:41:3'): resampling iterations equals folds * repeats ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:41:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingSpCVKnndm.R:10:3'): mlr3spatiotempcv indices are the same as CAST knndm: modeldomain ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:10:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) - ── Error ('test-ResamplingSpCVKnndm.R:38:3'): mlr3spatiotempcv indices are the same as CAST knndm: ppoints ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:38:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) + 1. ├─testthat::expect_error(...) at test-TaskClassifST.R:16:3 + 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. ├─rsmp("spcv_coords")$instantiate(tsk("boston_housing")) + 8. │ └─mlr3spatiotempcv:::.__ResamplingSpCVCoords__instantiate(...) + 9. │ └─mlr3::assert_task(task) + 10. │ └─checkmate::assert_class(task, "Task", .var.name = .var.name) + 11. │ └─checkmate::checkClass(x, classes, ordered, null.ok) + 12. └─mlr3::tsk("boston_housing") + 13. └─mlr3misc::dictionary_sugar_get(dict = mlr_tasks, .key, ...) + 14. └─mlr3misc:::dictionary_get(dict, .key) + 15. └─mlr3misc:::dictionary_retrieve_item(self, key) + 16. └─mlr3misc::stopf(...) - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] Deleting unused snapshots: • 1-autoplot/autoplot-show-blocks-true-show-labels-true.svg • 1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg @@ -273,7 +178,6 @@ Check the boxes above after successful execution and remove this line. Then run • 2-autoplot/spcvdisc-fold-1-2.svg • 2-autoplot/spcvdisc-fold-1.svg • 2-autoplot/spcvdisc-show-omitted.svg - • 2-autoplot/spcvknndm-all-test-sets.svg • 2-autoplot/spcvknndm-fold-1-2.svg • 2-autoplot/spcvknndm-fold-1.svg • 2-autoplot/sptcvcstf-2d-space-var-all-test-sets.svg @@ -294,7 +198,7 @@ Check the boxes above after successful execution and remove this line. Then run Error: Test failures Execution halted - [x] ERROR: r-devel-linux-x86_64-debian-gcc - Running ‘testthat.R’ [99s/92s] + Running ‘testthat.R’ [87s/59s] Running the tests in ‘tests/testthat.R’ failed. Complete output: > if (requireNamespace("testthat", quietly = TRUE)) { @@ -305,10 +209,10 @@ Check the boxes above after successful execution and remove this line. Then run + } Loading required package: mlr3 Starting 2 test processes - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] - ══ Skipped tests (23) ══════════════════════════════════════════════════════════ - • On CRAN (18): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', + ══ Skipped tests (24) ══════════════════════════════════════════════════════════ + • On CRAN (19): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', 'test-1-autoplot.R:98:3', 'test-1-autoplot.R:130:3', 'test-1-autoplot.R:157:3', 'test-1-autoplot.R:189:3', 'test-1-autoplot.R:224:3', 'test-1-autoplot.R:257:3', @@ -316,123 +220,36 @@ Check the boxes above after successful execution and remove this line. Then run 'test-1-autoplot.R:343:3', 'test-1-autoplot.R:377:3', 'test-2-autoplot.R:129:3', 'test-2-autoplot.R:182:3', 'test-2-autoplot.R:204:3', 'test-2-autoplot.R:246:3', - 'test-2-autoplot.R:300:3', 'test-autoplot_buffer.R:19:3' + 'test-2-autoplot.R:300:3', 'test-2-autoplot.R:352:3', + 'test-autoplot_buffer.R:19:3' • On Linux (2): 'test-2-autoplot.R:8:3', 'test-2-autoplot.R:54:3' • empty test (1): 'test-helper-DataBackend.R:1:1' • raster cannot be loaded (1): 'test-mlr3pipelines-graph-integration.R:4:3' • skmeans cannot be loaded (1): 'test-mlr_sptcv_generic.R:70:3' ══ Failed tests ════════════════════════════════════════════════════════════════ - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:21:3'): folds can be printed ───── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:21:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:31:3'): reps can be printed ────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) + ── Error ('test-TaskClassifST.R:16:3'): Supplying a non-spatio temporal task gives descriptive error message ── + Error: Element with key 'boston_housing' not found in DictionaryTask! Backtrace: ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:31:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:41:3'): resampling iterations equals folds * repeats ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:41:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-2-autoplot.R:331:3'): plot() works for 'spcv_knndm' ──────────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-2-autoplot.R:331:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingSpCVKnndm.R:10:3'): mlr3spatiotempcv indices are the same as CAST knndm: modeldomain ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:10:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) - ── Error ('test-ResamplingSpCVKnndm.R:38:3'): mlr3spatiotempcv indices are the same as CAST knndm: ppoints ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:38:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) + 1. ├─testthat::expect_error(...) at test-TaskClassifST.R:16:3 + 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. ├─rsmp("spcv_coords")$instantiate(tsk("boston_housing")) + 8. │ └─mlr3spatiotempcv:::.__ResamplingSpCVCoords__instantiate(...) + 9. │ └─mlr3::assert_task(task) + 10. │ └─checkmate::assert_class(task, "Task", .var.name = .var.name) + 11. │ └─checkmate::checkClass(x, classes, ordered, null.ok) + 12. └─mlr3::tsk("boston_housing") + 13. └─mlr3misc::dictionary_sugar_get(dict = mlr_tasks, .key, ...) + 14. └─mlr3misc:::dictionary_get(dict, .key) + 15. └─mlr3misc:::dictionary_retrieve_item(self, key) + 16. └─mlr3misc::stopf(...) - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] Deleting unused snapshots: • 1-autoplot/autoplot-show-blocks-true-show-labels-true.svg • 1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg @@ -507,7 +324,6 @@ Check the boxes above after successful execution and remove this line. Then run • 2-autoplot/spcvdisc-fold-1-2.svg • 2-autoplot/spcvdisc-fold-1.svg • 2-autoplot/spcvdisc-show-omitted.svg - • 2-autoplot/spcvknndm-all-test-sets.svg • 2-autoplot/spcvknndm-fold-1-2.svg • 2-autoplot/spcvknndm-fold-1.svg • 2-autoplot/sptcvcstf-2d-space-var-all-test-sets.svg @@ -527,49 +343,8 @@ Check the boxes above after successful execution and remove this line. Then run • autoplot_buffer/spcvbuffer-fold-1-2.svg Error: Test failures Execution halted -- [x] ERROR: r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-prerel-windows-x86_64, r-release-windows-x86_64, r-oldrel-windows-x86_64 - Running examples in ‘mlr3spatiotempcv-Ex.R’ failed - The error most likely occurred in: - - > ### Name: mlr_resamplings_repeated_spcv_knndm - > ### Title: (CAST) Repeated K-fold Nearest Neighbour Distance Matching - > ### Aliases: mlr_resamplings_repeated_spcv_knndm - > ### ResamplingRepeatedSpCVKnndm - > - > ### ** Examples - > - > library(mlr3) - > library(mlr3spatial) - - Attaching package: ‘mlr3spatial’ - - The following objects are masked from ‘package:mlr3spatiotempcv’: - - TaskClassifST, TaskRegrST, as_task_classif_st, - as_task_classif_st.DataBackend, as_task_classif_st.TaskClassifST, - as_task_classif_st.data.frame, as_task_classif_st.sf, - as_task_regr_st, as_task_regr_st.DataBackend, - as_task_regr_st.TaskClassifST, as_task_regr_st.TaskRegrST, - as_task_regr_st.data.frame, as_task_regr_st.sf - - > set.seed(42) - > simarea = list(matrix(c(0, 0, 0, 100, 100, 100, 100, 0, 0, 0), ncol = 2, byrow = TRUE)) - > simarea = sf::st_polygon(simarea) - > train_points = sf::st_sample(simarea, 1000, type = "random") - > train_points = sf::st_as_sf(train_points) - > train_points$target = as.factor(sample(c("TRUE", "FALSE"), 1000, replace = TRUE)) - > pred_points = sf::st_sample(simarea, 1000, type = "regular") - > - > task = mlr3spatial::as_task_classif_st(sf::st_as_sf(train_points), "target", positive = "TRUE") - > - > cv_knndm = rsmp("repeated_spcv_knndm", ppoints = pred_points, repeats = 2) - > cv_knndm$instantiate(task) - Error in CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, : - unused argument (ppoints = self$param_set$values$ppoints) - Calls: ... .__ResamplingRepeatedSpCVKnndm__.sample -> map -> lapply -> FUN - Execution halted - [x] ERROR: r-devel-linux-x86_64-fedora-clang - Running ‘testthat.R’ [154s/76s] + Running ‘testthat.R’ [183s/92s] Running the tests in ‘tests/testthat.R’ failed. Complete output: > if (requireNamespace("testthat", quietly = TRUE)) { @@ -580,10 +355,10 @@ Check the boxes above after successful execution and remove this line. Then run + } Loading required package: mlr3 Starting 2 test processes - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] - ══ Skipped tests (23) ══════════════════════════════════════════════════════════ - • On CRAN (18): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', + ══ Skipped tests (24) ══════════════════════════════════════════════════════════ + • On CRAN (19): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', 'test-1-autoplot.R:98:3', 'test-1-autoplot.R:130:3', 'test-1-autoplot.R:157:3', 'test-1-autoplot.R:189:3', 'test-1-autoplot.R:224:3', 'test-1-autoplot.R:257:3', @@ -591,123 +366,36 @@ Check the boxes above after successful execution and remove this line. Then run 'test-1-autoplot.R:343:3', 'test-1-autoplot.R:377:3', 'test-2-autoplot.R:129:3', 'test-2-autoplot.R:182:3', 'test-2-autoplot.R:204:3', 'test-2-autoplot.R:246:3', - 'test-2-autoplot.R:300:3', 'test-autoplot_buffer.R:19:3' + 'test-2-autoplot.R:300:3', 'test-2-autoplot.R:352:3', + 'test-autoplot_buffer.R:19:3' • On Linux (2): 'test-2-autoplot.R:8:3', 'test-2-autoplot.R:54:3' • empty test (1): 'test-helper-DataBackend.R:1:1' • raster cannot be loaded (1): 'test-mlr3pipelines-graph-integration.R:4:3' • skmeans cannot be loaded (1): 'test-mlr_sptcv_generic.R:70:3' ══ Failed tests ════════════════════════════════════════════════════════════════ - ── Error ('test-2-autoplot.R:331:3'): plot() works for 'spcv_knndm' ──────────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-2-autoplot.R:331:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:21:3'): folds can be printed ───── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:21:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:31:3'): reps can be printed ────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:31:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:41:3'): resampling iterations equals folds * repeats ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) + ── Error ('test-TaskClassifST.R:16:3'): Supplying a non-spatio temporal task gives descriptive error message ── + Error: Element with key 'boston_housing' not found in DictionaryTask! Backtrace: ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:41:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingSpCVKnndm.R:10:3'): mlr3spatiotempcv indices are the same as CAST knndm: modeldomain ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:10:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) - ── Error ('test-ResamplingSpCVKnndm.R:38:3'): mlr3spatiotempcv indices are the same as CAST knndm: ppoints ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:38:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) + 1. ├─testthat::expect_error(...) at test-TaskClassifST.R:16:3 + 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. ├─rsmp("spcv_coords")$instantiate(tsk("boston_housing")) + 8. │ └─mlr3spatiotempcv:::.__ResamplingSpCVCoords__instantiate(...) + 9. │ └─mlr3::assert_task(task) + 10. │ └─checkmate::assert_class(task, "Task", .var.name = .var.name) + 11. │ └─checkmate::checkClass(x, classes, ordered, null.ok) + 12. └─mlr3::tsk("boston_housing") + 13. └─mlr3misc::dictionary_sugar_get(dict = mlr_tasks, .key, ...) + 14. └─mlr3misc:::dictionary_get(dict, .key) + 15. └─mlr3misc:::dictionary_retrieve_item(self, key) + 16. └─mlr3misc::stopf(...) - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] Deleting unused snapshots: • 1-autoplot/autoplot-show-blocks-true-show-labels-true.svg • 1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg @@ -782,7 +470,6 @@ Check the boxes above after successful execution and remove this line. Then run • 2-autoplot/spcvdisc-fold-1-2.svg • 2-autoplot/spcvdisc-fold-1.svg • 2-autoplot/spcvdisc-show-omitted.svg - • 2-autoplot/spcvknndm-all-test-sets.svg • 2-autoplot/spcvknndm-fold-1-2.svg • 2-autoplot/spcvknndm-fold-1.svg • 2-autoplot/sptcvcstf-2d-space-var-all-test-sets.svg @@ -803,7 +490,7 @@ Check the boxes above after successful execution and remove this line. Then run Error: Test failures Execution halted - [x] ERROR: r-devel-linux-x86_64-fedora-gcc - Running ‘testthat.R’ [142s/87s] + Running ‘testthat.R’ [189s/106s] Running the tests in ‘tests/testthat.R’ failed. Complete output: > if (requireNamespace("testthat", quietly = TRUE)) { @@ -814,10 +501,10 @@ Check the boxes above after successful execution and remove this line. Then run + } Loading required package: mlr3 Starting 2 test processes - [ FAIL 6 | WARN 0 | SKIP 22 | PASS 1202 ] + [ FAIL 1 | WARN 1 | SKIP 23 | PASS 1211 ] - ══ Skipped tests (22) ══════════════════════════════════════════════════════════ - • On CRAN (19): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', + ══ Skipped tests (23) ══════════════════════════════════════════════════════════ + • On CRAN (20): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', 'test-1-autoplot.R:98:3', 'test-1-autoplot.R:130:3', 'test-1-autoplot.R:157:3', 'test-1-autoplot.R:189:3', 'test-1-autoplot.R:224:3', 'test-1-autoplot.R:257:3', @@ -825,122 +512,34 @@ Check the boxes above after successful execution and remove this line. Then run 'test-1-autoplot.R:343:3', 'test-1-autoplot.R:377:3', 'test-2-autoplot.R:129:3', 'test-2-autoplot.R:182:3', 'test-2-autoplot.R:204:3', 'test-2-autoplot.R:246:3', - 'test-2-autoplot.R:300:3', 'test-autoplot_buffer.R:19:3', - 'test-mlr3pipelines-graph-integration.R:5:3' + 'test-2-autoplot.R:300:3', 'test-2-autoplot.R:352:3', + 'test-autoplot_buffer.R:19:3', 'test-mlr3pipelines-graph-integration.R:5:3' • On Linux (2): 'test-2-autoplot.R:8:3', 'test-2-autoplot.R:54:3' • empty test (1): 'test-helper-DataBackend.R:1:1' ══ Failed tests ════════════════════════════════════════════════════════════════ - ── Error ('test-2-autoplot.R:331:3'): plot() works for 'spcv_knndm' ──────────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-2-autoplot.R:331:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:21:3'): folds can be printed ───── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:21:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:31:3'): reps can be printed ────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:31:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:41:3'): resampling iterations equals folds * repeats ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) + ── Error ('test-TaskClassifST.R:16:3'): Supplying a non-spatio temporal task gives descriptive error message ── + Error: Element with key 'boston_housing' not found in DictionaryTask! Backtrace: ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:41:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingSpCVKnndm.R:10:3'): mlr3spatiotempcv indices are the same as CAST knndm: modeldomain ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:10:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) - ── Error ('test-ResamplingSpCVKnndm.R:38:3'): mlr3spatiotempcv indices are the same as CAST knndm: ppoints ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:38:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) + 1. ├─testthat::expect_error(...) at test-TaskClassifST.R:16:3 + 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. ├─rsmp("spcv_coords")$instantiate(tsk("boston_housing")) + 8. │ └─mlr3spatiotempcv:::.__ResamplingSpCVCoords__instantiate(...) + 9. │ └─mlr3::assert_task(task) + 10. │ └─checkmate::assert_class(task, "Task", .var.name = .var.name) + 11. │ └─checkmate::checkClass(x, classes, ordered, null.ok) + 12. └─mlr3::tsk("boston_housing") + 13. └─mlr3misc::dictionary_sugar_get(dict = mlr_tasks, .key, ...) + 14. └─mlr3misc:::dictionary_get(dict, .key) + 15. └─mlr3misc:::dictionary_retrieve_item(self, key) + 16. └─mlr3misc::stopf(...) - [ FAIL 6 | WARN 0 | SKIP 22 | PASS 1202 ] + [ FAIL 1 | WARN 1 | SKIP 23 | PASS 1211 ] Deleting unused snapshots: • 1-autoplot/autoplot-show-blocks-true-show-labels-true.svg • 1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg @@ -1015,7 +614,6 @@ Check the boxes above after successful execution and remove this line. Then run • 2-autoplot/spcvdisc-fold-1-2.svg • 2-autoplot/spcvdisc-fold-1.svg • 2-autoplot/spcvdisc-show-omitted.svg - • 2-autoplot/spcvknndm-all-test-sets.svg • 2-autoplot/spcvknndm-fold-1-2.svg • 2-autoplot/spcvknndm-fold-1.svg • 2-autoplot/sptcvcstf-2d-space-var-all-test-sets.svg @@ -1035,8 +633,8 @@ Check the boxes above after successful execution and remove this line. Then run • autoplot_buffer/spcvbuffer-fold-1-2.svg Error: Test failures Execution halted -- [x] ERROR: r-prerel-windows-x86_64 - Running 'testthat.R' [46s] +- [x] ERROR: r-devel-windows-x86_64 + Running 'testthat.R' [51s] Running the tests in 'tests/testthat.R' failed. Complete output: > if (requireNamespace("testthat", quietly = TRUE)) { @@ -1047,10 +645,10 @@ Check the boxes above after successful execution and remove this line. Then run + } Loading required package: mlr3 Starting 2 test processes - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] - ══ Skipped tests (23) ══════════════════════════════════════════════════════════ - • On CRAN (18): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', + ══ Skipped tests (24) ══════════════════════════════════════════════════════════ + • On CRAN (19): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', 'test-1-autoplot.R:98:3', 'test-1-autoplot.R:130:3', 'test-1-autoplot.R:157:3', 'test-1-autoplot.R:189:3', 'test-1-autoplot.R:224:3', 'test-1-autoplot.R:257:3', @@ -1058,123 +656,36 @@ Check the boxes above after successful execution and remove this line. Then run 'test-1-autoplot.R:343:3', 'test-1-autoplot.R:377:3', 'test-2-autoplot.R:129:3', 'test-2-autoplot.R:182:3', 'test-2-autoplot.R:204:3', 'test-2-autoplot.R:246:3', - 'test-2-autoplot.R:300:3', 'test-autoplot_buffer.R:19:3' + 'test-2-autoplot.R:300:3', 'test-2-autoplot.R:352:3', + 'test-autoplot_buffer.R:19:3' • On Windows (2): 'test-2-autoplot.R:9:3', 'test-2-autoplot.R:55:3' • empty test (1): 'test-helper-DataBackend.R:1:1' • raster cannot be loaded (1): 'test-mlr3pipelines-graph-integration.R:4:3' • skmeans cannot be loaded (1): 'test-mlr_sptcv_generic.R:70:3' ══ Failed tests ════════════════════════════════════════════════════════════════ - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:21:3'): folds can be printed ───── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) + ── Error ('test-TaskClassifST.R:16:3'): Supplying a non-spatio temporal task gives descriptive error message ── + Error: Element with key 'boston_housing' not found in DictionaryTask! Backtrace: ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:21:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:31:3'): reps can be printed ────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:31:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:41:3'): resampling iterations equals folds * repeats ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:41:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingSpCVKnndm.R:10:3'): mlr3spatiotempcv indices are the same as CAST knndm: modeldomain ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:10:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) - ── Error ('test-ResamplingSpCVKnndm.R:38:3'): mlr3spatiotempcv indices are the same as CAST knndm: ppoints ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:38:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) - ── Error ('test-2-autoplot.R:331:3'): plot() works for 'spcv_knndm' ──────────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-2-autoplot.R:331:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) + 1. ├─testthat::expect_error(...) at test-TaskClassifST.R:16:3 + 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. ├─rsmp("spcv_coords")$instantiate(tsk("boston_housing")) + 8. │ └─mlr3spatiotempcv:::.__ResamplingSpCVCoords__instantiate(...) + 9. │ └─mlr3::assert_task(task) + 10. │ └─checkmate::assert_class(task, "Task", .var.name = .var.name) + 11. │ └─checkmate::checkClass(x, classes, ordered, null.ok) + 12. └─mlr3::tsk("boston_housing") + 13. └─mlr3misc::dictionary_sugar_get(dict = mlr_tasks, .key, ...) + 14. └─mlr3misc:::dictionary_get(dict, .key) + 15. └─mlr3misc:::dictionary_retrieve_item(self, key) + 16. └─mlr3misc::stopf(...) - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] Deleting unused snapshots: • 1-autoplot/autoplot-show-blocks-true-show-labels-true.svg • 1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg @@ -1249,7 +760,6 @@ Check the boxes above after successful execution and remove this line. Then run • 2-autoplot/spcvdisc-fold-1-2.svg • 2-autoplot/spcvdisc-fold-1.svg • 2-autoplot/spcvdisc-show-omitted.svg - • 2-autoplot/spcvknndm-all-test-sets.svg • 2-autoplot/spcvknndm-fold-1-2.svg • 2-autoplot/spcvknndm-fold-1.svg • 2-autoplot/sptcvcstf-2d-space-var-all-test-sets.svg @@ -1270,7 +780,7 @@ Check the boxes above after successful execution and remove this line. Then run Error: Test failures Execution halted - [x] ERROR: r-patched-linux-x86_64 - Running ‘testthat.R’ [124s/87s] + Running ‘testthat.R’ [102s/55s] Running the tests in ‘tests/testthat.R’ failed. Complete output: > if (requireNamespace("testthat", quietly = TRUE)) { @@ -1281,244 +791,10 @@ Check the boxes above after successful execution and remove this line. Then run + } Loading required package: mlr3 Starting 2 test processes - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] - - ══ Skipped tests (23) ══════════════════════════════════════════════════════════ - • On CRAN (18): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', - 'test-1-autoplot.R:98:3', 'test-1-autoplot.R:130:3', - 'test-1-autoplot.R:157:3', 'test-1-autoplot.R:189:3', - 'test-1-autoplot.R:224:3', 'test-1-autoplot.R:257:3', - 'test-1-autoplot.R:268:3', 'test-1-autoplot.R:315:3', - 'test-1-autoplot.R:343:3', 'test-1-autoplot.R:377:3', - 'test-2-autoplot.R:129:3', 'test-2-autoplot.R:182:3', - 'test-2-autoplot.R:204:3', 'test-2-autoplot.R:246:3', - 'test-2-autoplot.R:300:3', 'test-autoplot_buffer.R:19:3' - • On Linux (2): 'test-2-autoplot.R:8:3', 'test-2-autoplot.R:54:3' - • empty test (1): 'test-helper-DataBackend.R:1:1' - • raster cannot be loaded (1): 'test-mlr3pipelines-graph-integration.R:4:3' - • skmeans cannot be loaded (1): 'test-mlr_sptcv_generic.R:70:3' - - ══ Failed tests ════════════════════════════════════════════════════════════════ - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:21:3'): folds can be printed ───── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:21:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:31:3'): reps can be printed ────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:31:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:41:3'): resampling iterations equals folds * repeats ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:41:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-2-autoplot.R:331:3'): plot() works for 'spcv_knndm' ──────────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-2-autoplot.R:331:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingSpCVKnndm.R:10:3'): mlr3spatiotempcv indices are the same as CAST knndm: modeldomain ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:10:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) - ── Error ('test-ResamplingSpCVKnndm.R:38:3'): mlr3spatiotempcv indices are the same as CAST knndm: ppoints ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:38:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] - Deleting unused snapshots: - • 1-autoplot/autoplot-show-blocks-true-show-labels-true.svg - • 1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg - • 1-autoplot/custom-cv-fold-1-2.svg - • 1-autoplot/custom-cv-fold-1-sample-fold-n.svg - • 1-autoplot/custom-cv-fold-1.svg - • 1-autoplot/custom-cv-sample-fold-n.svg - • 1-autoplot/cv-fold-1-2-groups-col-role.svg - • 1-autoplot/cv-fold-1-2-sample-fold-n.svg - • 1-autoplot/cv-fold-1-2.svg - • 1-autoplot/cv-fold-1-groups-col-role.svg - • 1-autoplot/cv-fold-1-sample-fold-n.svg - • 1-autoplot/cv-fold-1.svg - • 1-autoplot/cv-sample-fold-n.svg - • 1-autoplot/repcv-fold-1-2-rep-1.svg - • 1-autoplot/repcv-fold-1-2-rep-2.svg - • 1-autoplot/repcv-fold-1-rep-1.svg - • 1-autoplot/repcv-fold-1-rep-2.svg - • 1-autoplot/repspcvblock-fold-1-2-rep-1.svg - • 1-autoplot/repspcvblock-fold-1-2-rep-2.svg - • 1-autoplot/repspcvblock-fold-1-rep-1.svg - • 1-autoplot/repspcvblock-fold-1-rep-2.svg - • 1-autoplot/repspcvcoords-fold-1-2-rep-1.svg - • 1-autoplot/repspcvcoords-fold-1-2-rep-2.svg - • 1-autoplot/repspcvcoords-fold-1-2-sample-fold-n.svg - • 1-autoplot/repspcvcoords-fold-1-rep-1.svg - • 1-autoplot/repspcvcoords-fold-1-rep-2.svg - • 1-autoplot/repspcvcoords-fold-1-sample-fold-n.svg - • 1-autoplot/repspcvcoords-sample-fold-n.svg - • 1-autoplot/repspcvenv-fold-1-2-rep-1.svg - • 1-autoplot/repspcvenv-fold-1-2-rep-2.svg - • 1-autoplot/repspcvenv-fold-1-rep-1.svg - • 1-autoplot/repspcvenv-fold-1-rep-2.svg - • 1-autoplot/spcvblock-fold-1-2-sample-fold-n.svg - • 1-autoplot/spcvblock-fold-1-2.svg - • 1-autoplot/spcvblock-fold-1-sample-fold-n.svg - • 1-autoplot/spcvblock-fold-1.svg - • 1-autoplot/spcvblock-sample-fold-n.svg - • 1-autoplot/spcvcoords-fold-1-2.svg - • 1-autoplot/spcvcoords-fold-1.svg - • 1-autoplot/spcvenv-fold-1-2-sample-fold-n.svg - • 1-autoplot/spcvenv-fold-1-2.svg - • 1-autoplot/spcvenv-fold-1-sample-fold-n.svg - • 1-autoplot/spcvenv-fold-1.svg - • 1-autoplot/spcvenv-sample-fold-n.svg - • 2-autoplot/repspcvdisc-fold-1-2-rep-2.svg - • 2-autoplot/repspcvdisc-fold-1-2-sample-fold-n.svg - • 2-autoplot/repspcvdisc-fold-1-rep-1-sample-n-fold.svg - • 2-autoplot/repspcvdisc-fold-1-rep-2.svg - • 2-autoplot/repspcvdisc-fold-1-sample-fold-n.svg - • 2-autoplot/repspcvdisc-sample-fold-n.svg - • 2-autoplot/repspcvknndm-fold-1-2-rep-2.svg - • 2-autoplot/repspcvknndm-fold-1-2-sample-fold-n.svg - • 2-autoplot/repspcvknndm-fold-1-rep-1-sample-n-fold.svg - • 2-autoplot/repspcvknndm-fold-1-rep-2.svg - • 2-autoplot/repspcvknndm-fold-1-sample-fold-n.svg - • 2-autoplot/repspcvknndm-sample-fold-n.svg - • 2-autoplot/repspcvtiles-fold-1-2-rep-2.svg - • 2-autoplot/repspcvtiles-fold-1-2-sample-fold-n.svg - • 2-autoplot/repspcvtiles-fold-1-2.svg - • 2-autoplot/repspcvtiles-fold-1-rep-2.svg - • 2-autoplot/repspcvtiles-fold-1-sample-fold-n.svg - • 2-autoplot/repspcvtiles-fold-1.svg - • 2-autoplot/repspcvtiles-sample-fold-n.svg - • 2-autoplot/repspcvtiles-show-omitted.svg - • 2-autoplot/repsptcvcstf-2d-space-var-fold-1-2-rep-2.svg - • 2-autoplot/repsptcvcstf-2d-space-var-fold-1-rep-2.svg - • 2-autoplot/repsptcvcstf-fold-1-2-rep-1.svg - • 2-autoplot/repsptcvcstf-fold-1-2-rep-2.svg - • 2-autoplot/repsptcvcstf-fold-1-rep-1-sample-fold-n.svg - • 2-autoplot/repsptcvcstf-fold-1-rep-2.svg - • 2-autoplot/spcvdisc-fold-1-2.svg - • 2-autoplot/spcvdisc-fold-1.svg - • 2-autoplot/spcvdisc-show-omitted.svg - • 2-autoplot/spcvknndm-all-test-sets.svg - • 2-autoplot/spcvknndm-fold-1-2.svg - • 2-autoplot/spcvknndm-fold-1.svg - • 2-autoplot/sptcvcstf-2d-space-var-all-test-sets.svg - • 2-autoplot/sptcvcstf-2d-space-var-fold-1-2.svg - • 2-autoplot/sptcvcstf-2d-space-var-fold-1.svg - • 2-autoplot/sptcvcstf-2d-time-var-all-test-sets.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1-2-rep-2.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1-2-sample-fold-n.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1-2.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1-rep-2.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1-sample-fold-n.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1.svg - • 2-autoplot/sptcvcstf-2d-time-var-sample-fold-n.svg - • 2-autoplot/sptcvcstf-3d-time-var-fold-1-2-sample-fold-n.svg - • 2-autoplot/sptcvcstf-3d-time-var-fold-1-2.svg - • 2-autoplot/sptcvcstf-3d-time-var-fold-1-sample-fold-n.svg - • autoplot_buffer/spcvbuffer-fold-1-2.svg - Error: Test failures - Execution halted -- [x] ERROR: r-release-linux-x86_64 - Running ‘testthat.R’ [129s/98s] - Running the tests in ‘tests/testthat.R’ failed. - Complete output: - > if (requireNamespace("testthat", quietly = TRUE)) { - + library("checkmate") - + library("testthat") - + library("mlr3spatiotempcv") - + test_check("mlr3spatiotempcv") - + } - Loading required package: mlr3 - Starting 2 test processes - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] - - ══ Skipped tests (23) ══════════════════════════════════════════════════════════ - • On CRAN (18): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', + ══ Skipped tests (24) ══════════════════════════════════════════════════════════ + • On CRAN (19): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', 'test-1-autoplot.R:98:3', 'test-1-autoplot.R:130:3', 'test-1-autoplot.R:157:3', 'test-1-autoplot.R:189:3', 'test-1-autoplot.R:224:3', 'test-1-autoplot.R:257:3', @@ -1526,123 +802,36 @@ Check the boxes above after successful execution and remove this line. Then run 'test-1-autoplot.R:343:3', 'test-1-autoplot.R:377:3', 'test-2-autoplot.R:129:3', 'test-2-autoplot.R:182:3', 'test-2-autoplot.R:204:3', 'test-2-autoplot.R:246:3', - 'test-2-autoplot.R:300:3', 'test-autoplot_buffer.R:19:3' + 'test-2-autoplot.R:300:3', 'test-2-autoplot.R:352:3', + 'test-autoplot_buffer.R:19:3' • On Linux (2): 'test-2-autoplot.R:8:3', 'test-2-autoplot.R:54:3' • empty test (1): 'test-helper-DataBackend.R:1:1' • raster cannot be loaded (1): 'test-mlr3pipelines-graph-integration.R:4:3' • skmeans cannot be loaded (1): 'test-mlr_sptcv_generic.R:70:3' ══ Failed tests ════════════════════════════════════════════════════════════════ - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:21:3'): folds can be printed ───── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:21:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:31:3'): reps can be printed ────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:31:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:41:3'): resampling iterations equals folds * repeats ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:41:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-2-autoplot.R:331:3'): plot() works for 'spcv_knndm' ──────────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-2-autoplot.R:331:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingSpCVKnndm.R:10:3'): mlr3spatiotempcv indices are the same as CAST knndm: modeldomain ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) + ── Error ('test-TaskClassifST.R:16:3'): Supplying a non-spatio temporal task gives descriptive error message ── + Error: Element with key 'boston_housing' not found in DictionaryTask! Backtrace: ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:10:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) - ── Error ('test-ResamplingSpCVKnndm.R:38:3'): mlr3spatiotempcv indices are the same as CAST knndm: ppoints ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:38:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) + 1. ├─testthat::expect_error(...) at test-TaskClassifST.R:16:3 + 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. ├─rsmp("spcv_coords")$instantiate(tsk("boston_housing")) + 8. │ └─mlr3spatiotempcv:::.__ResamplingSpCVCoords__instantiate(...) + 9. │ └─mlr3::assert_task(task) + 10. │ └─checkmate::assert_class(task, "Task", .var.name = .var.name) + 11. │ └─checkmate::checkClass(x, classes, ordered, null.ok) + 12. └─mlr3::tsk("boston_housing") + 13. └─mlr3misc::dictionary_sugar_get(dict = mlr_tasks, .key, ...) + 14. └─mlr3misc:::dictionary_get(dict, .key) + 15. └─mlr3misc:::dictionary_retrieve_item(self, key) + 16. └─mlr3misc::stopf(...) - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] Deleting unused snapshots: • 1-autoplot/autoplot-show-blocks-true-show-labels-true.svg • 1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg @@ -1717,241 +906,6 @@ Check the boxes above after successful execution and remove this line. Then run • 2-autoplot/spcvdisc-fold-1-2.svg • 2-autoplot/spcvdisc-fold-1.svg • 2-autoplot/spcvdisc-show-omitted.svg - • 2-autoplot/spcvknndm-all-test-sets.svg - • 2-autoplot/spcvknndm-fold-1-2.svg - • 2-autoplot/spcvknndm-fold-1.svg - • 2-autoplot/sptcvcstf-2d-space-var-all-test-sets.svg - • 2-autoplot/sptcvcstf-2d-space-var-fold-1-2.svg - • 2-autoplot/sptcvcstf-2d-space-var-fold-1.svg - • 2-autoplot/sptcvcstf-2d-time-var-all-test-sets.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1-2-rep-2.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1-2-sample-fold-n.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1-2.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1-rep-2.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1-sample-fold-n.svg - • 2-autoplot/sptcvcstf-2d-time-var-fold-1.svg - • 2-autoplot/sptcvcstf-2d-time-var-sample-fold-n.svg - • 2-autoplot/sptcvcstf-3d-time-var-fold-1-2-sample-fold-n.svg - • 2-autoplot/sptcvcstf-3d-time-var-fold-1-2.svg - • 2-autoplot/sptcvcstf-3d-time-var-fold-1-sample-fold-n.svg - • autoplot_buffer/spcvbuffer-fold-1-2.svg - Error: Test failures - Execution halted -- [x] ERROR: r-release-windows-x86_64 - Running 'testthat.R' [70s] - Running the tests in 'tests/testthat.R' failed. - Complete output: - > if (requireNamespace("testthat", quietly = TRUE)) { - + library("checkmate") - + library("testthat") - + library("mlr3spatiotempcv") - + test_check("mlr3spatiotempcv") - + } - Loading required package: mlr3 - Starting 2 test processes - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] - - ══ Skipped tests (23) ══════════════════════════════════════════════════════════ - • On CRAN (18): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', - 'test-1-autoplot.R:98:3', 'test-1-autoplot.R:130:3', - 'test-1-autoplot.R:157:3', 'test-1-autoplot.R:189:3', - 'test-1-autoplot.R:224:3', 'test-1-autoplot.R:257:3', - 'test-1-autoplot.R:268:3', 'test-1-autoplot.R:315:3', - 'test-1-autoplot.R:343:3', 'test-1-autoplot.R:377:3', - 'test-2-autoplot.R:129:3', 'test-2-autoplot.R:182:3', - 'test-2-autoplot.R:204:3', 'test-2-autoplot.R:246:3', - 'test-2-autoplot.R:300:3', 'test-autoplot_buffer.R:19:3' - • On Windows (2): 'test-2-autoplot.R:9:3', 'test-2-autoplot.R:55:3' - • empty test (1): 'test-helper-DataBackend.R:1:1' - • raster cannot be loaded (1): 'test-mlr3pipelines-graph-integration.R:4:3' - • skmeans cannot be loaded (1): 'test-mlr_sptcv_generic.R:70:3' - - ══ Failed tests ════════════════════════════════════════════════════════════════ - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:21:3'): folds can be printed ───── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:21:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:31:3'): reps can be printed ────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:31:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:41:3'): resampling iterations equals folds * repeats ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:41:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-2-autoplot.R:331:3'): plot() works for 'spcv_knndm' ──────────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-2-autoplot.R:331:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingSpCVKnndm.R:10:3'): mlr3spatiotempcv indices are the same as CAST knndm: modeldomain ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:10:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) - ── Error ('test-ResamplingSpCVKnndm.R:38:3'): mlr3spatiotempcv indices are the same as CAST knndm: ppoints ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:38:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) - - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] - Deleting unused snapshots: - • 1-autoplot/autoplot-show-blocks-true-show-labels-true.svg - • 1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg - • 1-autoplot/custom-cv-fold-1-2.svg - • 1-autoplot/custom-cv-fold-1-sample-fold-n.svg - • 1-autoplot/custom-cv-fold-1.svg - • 1-autoplot/custom-cv-sample-fold-n.svg - • 1-autoplot/cv-fold-1-2-groups-col-role.svg - • 1-autoplot/cv-fold-1-2-sample-fold-n.svg - • 1-autoplot/cv-fold-1-2.svg - • 1-autoplot/cv-fold-1-groups-col-role.svg - • 1-autoplot/cv-fold-1-sample-fold-n.svg - • 1-autoplot/cv-fold-1.svg - • 1-autoplot/cv-sample-fold-n.svg - • 1-autoplot/repcv-fold-1-2-rep-1.svg - • 1-autoplot/repcv-fold-1-2-rep-2.svg - • 1-autoplot/repcv-fold-1-rep-1.svg - • 1-autoplot/repcv-fold-1-rep-2.svg - • 1-autoplot/repspcvblock-fold-1-2-rep-1.svg - • 1-autoplot/repspcvblock-fold-1-2-rep-2.svg - • 1-autoplot/repspcvblock-fold-1-rep-1.svg - • 1-autoplot/repspcvblock-fold-1-rep-2.svg - • 1-autoplot/repspcvcoords-fold-1-2-rep-1.svg - • 1-autoplot/repspcvcoords-fold-1-2-rep-2.svg - • 1-autoplot/repspcvcoords-fold-1-2-sample-fold-n.svg - • 1-autoplot/repspcvcoords-fold-1-rep-1.svg - • 1-autoplot/repspcvcoords-fold-1-rep-2.svg - • 1-autoplot/repspcvcoords-fold-1-sample-fold-n.svg - • 1-autoplot/repspcvcoords-sample-fold-n.svg - • 1-autoplot/repspcvenv-fold-1-2-rep-1.svg - • 1-autoplot/repspcvenv-fold-1-2-rep-2.svg - • 1-autoplot/repspcvenv-fold-1-rep-1.svg - • 1-autoplot/repspcvenv-fold-1-rep-2.svg - • 1-autoplot/spcvblock-fold-1-2-sample-fold-n.svg - • 1-autoplot/spcvblock-fold-1-2.svg - • 1-autoplot/spcvblock-fold-1-sample-fold-n.svg - • 1-autoplot/spcvblock-fold-1.svg - • 1-autoplot/spcvblock-sample-fold-n.svg - • 1-autoplot/spcvcoords-fold-1-2.svg - • 1-autoplot/spcvcoords-fold-1.svg - • 1-autoplot/spcvenv-fold-1-2-sample-fold-n.svg - • 1-autoplot/spcvenv-fold-1-2.svg - • 1-autoplot/spcvenv-fold-1-sample-fold-n.svg - • 1-autoplot/spcvenv-fold-1.svg - • 1-autoplot/spcvenv-sample-fold-n.svg - • 2-autoplot/repspcvdisc-fold-1-2-rep-2.svg - • 2-autoplot/repspcvdisc-fold-1-2-sample-fold-n.svg - • 2-autoplot/repspcvdisc-fold-1-rep-1-sample-n-fold.svg - • 2-autoplot/repspcvdisc-fold-1-rep-2.svg - • 2-autoplot/repspcvdisc-fold-1-sample-fold-n.svg - • 2-autoplot/repspcvdisc-sample-fold-n.svg - • 2-autoplot/repspcvknndm-fold-1-2-rep-2.svg - • 2-autoplot/repspcvknndm-fold-1-2-sample-fold-n.svg - • 2-autoplot/repspcvknndm-fold-1-rep-1-sample-n-fold.svg - • 2-autoplot/repspcvknndm-fold-1-rep-2.svg - • 2-autoplot/repspcvknndm-fold-1-sample-fold-n.svg - • 2-autoplot/repspcvknndm-sample-fold-n.svg - • 2-autoplot/repspcvtiles-fold-1-2-rep-2.svg - • 2-autoplot/repspcvtiles-fold-1-2-sample-fold-n.svg - • 2-autoplot/repspcvtiles-fold-1-2.svg - • 2-autoplot/repspcvtiles-fold-1-rep-2.svg - • 2-autoplot/repspcvtiles-fold-1-sample-fold-n.svg - • 2-autoplot/repspcvtiles-fold-1.svg - • 2-autoplot/repspcvtiles-sample-fold-n.svg - • 2-autoplot/repspcvtiles-show-omitted.svg - • 2-autoplot/repsptcvcstf-2d-space-var-fold-1-2-rep-2.svg - • 2-autoplot/repsptcvcstf-2d-space-var-fold-1-rep-2.svg - • 2-autoplot/repsptcvcstf-fold-1-2-rep-1.svg - • 2-autoplot/repsptcvcstf-fold-1-2-rep-2.svg - • 2-autoplot/repsptcvcstf-fold-1-rep-1-sample-fold-n.svg - • 2-autoplot/repsptcvcstf-fold-1-rep-2.svg - • 2-autoplot/spcvdisc-fold-1-2.svg - • 2-autoplot/spcvdisc-fold-1.svg - • 2-autoplot/spcvdisc-show-omitted.svg - • 2-autoplot/spcvknndm-all-test-sets.svg • 2-autoplot/spcvknndm-fold-1-2.svg • 2-autoplot/spcvknndm-fold-1.svg • 2-autoplot/sptcvcstf-2d-space-var-all-test-sets.svg @@ -1972,7 +926,7 @@ Check the boxes above after successful execution and remove this line. Then run Error: Test failures Execution halted - [x] ERROR: r-oldrel-windows-x86_64 - Running 'testthat.R' [64s] + Running 'testthat.R' [76s] Running the tests in 'tests/testthat.R' failed. Complete output: > if (requireNamespace("testthat", quietly = TRUE)) { @@ -1983,10 +937,10 @@ Check the boxes above after successful execution and remove this line. Then run + } Loading required package: mlr3 Starting 2 test processes - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] - ══ Skipped tests (23) ══════════════════════════════════════════════════════════ - • On CRAN (18): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', + ══ Skipped tests (24) ══════════════════════════════════════════════════════════ + • On CRAN (19): 'test-1-autoplot.R:40:3', 'test-1-autoplot.R:72:3', 'test-1-autoplot.R:98:3', 'test-1-autoplot.R:130:3', 'test-1-autoplot.R:157:3', 'test-1-autoplot.R:189:3', 'test-1-autoplot.R:224:3', 'test-1-autoplot.R:257:3', @@ -1994,123 +948,36 @@ Check the boxes above after successful execution and remove this line. Then run 'test-1-autoplot.R:343:3', 'test-1-autoplot.R:377:3', 'test-2-autoplot.R:129:3', 'test-2-autoplot.R:182:3', 'test-2-autoplot.R:204:3', 'test-2-autoplot.R:246:3', - 'test-2-autoplot.R:300:3', 'test-autoplot_buffer.R:19:3' + 'test-2-autoplot.R:300:3', 'test-2-autoplot.R:352:3', + 'test-autoplot_buffer.R:19:3' • On Windows (2): 'test-2-autoplot.R:9:3', 'test-2-autoplot.R:55:3' • empty test (1): 'test-helper-DataBackend.R:1:1' • raster cannot be loaded (1): 'test-mlr3pipelines-graph-integration.R:4:3' • skmeans cannot be loaded (1): 'test-mlr_sptcv_generic.R:70:3' ══ Failed tests ════════════════════════════════════════════════════════════════ - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:21:3'): folds can be printed ───── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:21:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:31:3'): reps can be printed ────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:31:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingRepeatedSpCVKnndm.R:41:3'): resampling iterations equals folds * repeats ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-ResamplingRepeatedSpCVKnndm.R:41:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-2-autoplot.R:331:3'): plot() works for 'spcv_knndm' ──────────── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsp$instantiate(task))) at test-2-autoplot.R:331:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingRepeatedSpCVKnndm__.sample(...) - 9. └─mlr3misc::map(...) - 10. └─base::lapply(.x, .f, ...) - 11. └─mlr3spatiotempcv (local) FUN(X[[i]], ...) - ── Error ('test-ResamplingSpCVKnndm.R:10:3'): mlr3spatiotempcv indices are the same as CAST knndm: modeldomain ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) - Backtrace: - ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:10:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) - ── Error ('test-ResamplingSpCVKnndm.R:38:3'): mlr3spatiotempcv indices are the same as CAST knndm: ppoints ── - Error in `CAST::knndm(tpoints = points, modeldomain = self$param_set$values$modeldomain, - ppoints = self$param_set$values$ppoints, k = self$param_set$values$folds, - maxp = self$param_set$values$maxp, clustering = self$param_set$values$clustering, - linkf = self$param_set$values$linkf, samplesize = self$param_set$values$samplesize, - sampling = self$param_set$values$sampling)`: unused argument (ppoints = self$param_set$values$ppoints) + ── Error ('test-TaskClassifST.R:16:3'): Supplying a non-spatio temporal task gives descriptive error message ── + Error: Element with key 'boston_housing' not found in DictionaryTask! Backtrace: ▆ - 1. ├─base::suppressMessages(suppressWarnings(rsmp$instantiate(task))) at test-ResamplingSpCVKnndm.R:38:3 - 2. │ └─base::withCallingHandlers(...) - 3. ├─base::suppressWarnings(rsmp$instantiate(task)) - 4. │ └─base::withCallingHandlers(...) - 5. └─rsmp$instantiate(task) - 6. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__instantiate(...) - 7. └─private$.sample(task$row_ids, task$coordinates(), task$crs) - 8. └─mlr3spatiotempcv:::.__ResamplingSpCVKnndm__.sample(...) + 1. ├─testthat::expect_error(...) at test-TaskClassifST.R:16:3 + 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. ├─rsmp("spcv_coords")$instantiate(tsk("boston_housing")) + 8. │ └─mlr3spatiotempcv:::.__ResamplingSpCVCoords__instantiate(...) + 9. │ └─mlr3::assert_task(task) + 10. │ └─checkmate::assert_class(task, "Task", .var.name = .var.name) + 11. │ └─checkmate::checkClass(x, classes, ordered, null.ok) + 12. └─mlr3::tsk("boston_housing") + 13. └─mlr3misc::dictionary_sugar_get(dict = mlr_tasks, .key, ...) + 14. └─mlr3misc:::dictionary_get(dict, .key) + 15. └─mlr3misc:::dictionary_retrieve_item(self, key) + 16. └─mlr3misc::stopf(...) - [ FAIL 6 | WARN 0 | SKIP 23 | PASS 1197 ] + [ FAIL 1 | WARN 1 | SKIP 24 | PASS 1206 ] Deleting unused snapshots: • 1-autoplot/autoplot-show-blocks-true-show-labels-true.svg • 1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg @@ -2185,7 +1052,6 @@ Check the boxes above after successful execution and remove this line. Then run • 2-autoplot/spcvdisc-fold-1-2.svg • 2-autoplot/spcvdisc-fold-1.svg • 2-autoplot/spcvdisc-show-omitted.svg - • 2-autoplot/spcvknndm-all-test-sets.svg • 2-autoplot/spcvknndm-fold-1-2.svg • 2-autoplot/spcvknndm-fold-1.svg • 2-autoplot/sptcvcstf-2d-space-var-all-test-sets.svg diff --git a/inst/CITATION b/inst/CITATION new file mode 100644 index 00000000..2cd85dce --- /dev/null +++ b/inst/CITATION @@ -0,0 +1,23 @@ +bibentry(bibtype = "Article", + title = "{mlr3spatiotempcv}: Spatiotemporal Resampling Methods for Machine Learning in {R}", + author = c(person(given = "Patrick", + family = "Schratz", + email = "alexander.brenning@uni-jena.de"), + person(given = "Marc", + family = "Becker", + email = "marc.becker@stat.uni-muenchen.de"), + person(given = "Michel", + family = "Lang", + email = "lang@statistik.tu-dortmund.de"), + person(given = "Alexander", + family = "Brenning", + email = "patrick.schratz@uni-jena.de")), + journal = "Journal of Statistical Software", + year = "2024", + volume = "111", + number = "7", + pages = "1--36", + doi = "10.18637/jss.v111.i07", + header = "To cite mlr3spatiotempcv in publications use:" +) + diff --git a/man-roxygen/rox_param_backend.R b/man-roxygen/rox_param_backend.R index 7a3c3859..938d6f3d 100644 --- a/man-roxygen/rox_param_backend.R +++ b/man-roxygen/rox_param_backend.R @@ -1,4 +1,4 @@ -#' @param backend ([DataBackend])\cr -#' Either a [DataBackend], or any object which is convertible to a -#' [DataBackend] with `as_data_backend()`. -#' E.g., am `sf` will be converted to a [DataBackendDataTable]. +#' @param backend ([mlr3::DataBackend])\cr +#' Either a [mlr3::DataBackend], or any object which is convertible to a +#' [mlr3::DataBackend] with `as_data_backend()`. +#' E.g., am `sf` will be converted to a [mlr3::DataBackendDataTable]. diff --git a/man-roxygen/rox_param_extra_args.R b/man-roxygen/rox_param_extra_args.R index 2d6311c4..62e335ff 100644 --- a/man-roxygen/rox_param_extra_args.R +++ b/man-roxygen/rox_param_extra_args.R @@ -1,3 +1,3 @@ #' @param extra_args (named `list()`)\cr #' Named list of constructor arguments, required for converting task types -#' via [convert_task()]. +#' via [mlr3::convert_task()]. diff --git a/man-roxygen/seealso_task.R b/man-roxygen/seealso_task.R index 150d1102..3884ff42 100644 --- a/man-roxygen/seealso_task.R +++ b/man-roxygen/seealso_task.R @@ -1,5 +1,5 @@ #' @seealso -#' [Dictionary][mlr3misc::Dictionary] of [Tasks][Task]: [mlr_tasks] +#' [Dictionary][mlr3misc::Dictionary] of [Tasks][mlr3::Task]: [mlr3::mlr_tasks] #' -#' `as.data.table(mlr_tasks)` for a complete table of all (also dynamically created) [Tasks][Task]. +#' `as.data.table(mlr_tasks)` for a complete table of all (also dynamically created) [Tasks][mlr3::Task]. #' @family Task diff --git a/man/TaskClassifST.Rd b/man/TaskClassifST.Rd index c12ff154..41a92d09 100644 --- a/man/TaskClassifST.Rd +++ b/man/TaskClassifST.Rd @@ -4,7 +4,7 @@ \alias{TaskClassifST} \title{Create a Spatiotemporal Classification Task} \description{ -This task specializes \link{Task} and \link{TaskSupervised} for +This task specializes \link[mlr3:Task]{mlr3::Task} and \link[mlr3:TaskSupervised]{mlr3::TaskSupervised} for spatiotemporal classification problems. The target column is assumed to be a factor. The \code{task_type} is set to \code{"classif"} and \code{"spatiotemporal"}. @@ -81,6 +81,7 @@ that the coordinates in the data are named \code{"x"} and \code{"y"}.}
  • mlr3::Task$add_strata()
  • mlr3::Task$cbind()
  • mlr3::Task$data()
  • +
  • mlr3::Task$divide()
  • mlr3::Task$filter()
  • mlr3::Task$format()
  • mlr3::Task$formula()
  • @@ -124,10 +125,10 @@ Create a new spatiotemporal resampling Task \item{\code{id}}{(\code{character(1)})\cr Identifier for the new instance.} -\item{\code{backend}}{(\link{DataBackend})\cr -Either a \link{DataBackend}, or any object which is convertible to a -\link{DataBackend} with \code{as_data_backend()}. -E.g., am \code{sf} will be converted to a \link{DataBackendDataTable}.} +\item{\code{backend}}{(\link[mlr3:DataBackend]{mlr3::DataBackend})\cr +Either a \link[mlr3:DataBackend]{mlr3::DataBackend}, or any object which is convertible to a +\link[mlr3:DataBackend]{mlr3::DataBackend} with \code{as_data_backend()}. +E.g., am \code{sf} will be converted to a \link[mlr3:DataBackendDataTable]{mlr3::DataBackendDataTable}.} \item{\code{target}}{(\code{character(1)})\cr Name of the target column.} @@ -156,7 +157,7 @@ that the coordinates in the data are named \code{"x"} and \code{"y"}.} \item{\code{extra_args}}{(named \code{list()})\cr Named list of constructor arguments, required for converting task types -via \code{\link[=convert_task]{convert_task()}}.} +via \code{\link[mlr3:convert_task]{mlr3::convert_task()}}.} } \if{html}{\out{}} } diff --git a/man/TaskRegrST.Rd b/man/TaskRegrST.Rd index 7e28cb1f..0cdae6b4 100644 --- a/man/TaskRegrST.Rd +++ b/man/TaskRegrST.Rd @@ -4,7 +4,7 @@ \alias{TaskRegrST} \title{Create a Spatiotemporal Regression Task} \description{ -This task specializes \link{Task} and \link{TaskSupervised} for spatiotemporal +This task specializes \link[mlr3:Task]{mlr3::Task} and \link[mlr3:TaskSupervised]{mlr3::TaskSupervised} for spatiotemporal classification problems. A spatial example task is available via \code{tsk("ecuador")}, a spatiotemporal @@ -58,6 +58,7 @@ that the coordinates in the data are named \code{"x"} and \code{"y"}.}
  • mlr3::Task$add_strata()
  • mlr3::Task$cbind()
  • mlr3::Task$data()
  • +
  • mlr3::Task$divide()
  • mlr3::Task$droplevels()
  • mlr3::Task$filter()
  • mlr3::Task$format()
  • @@ -101,10 +102,10 @@ Returns coordinates of observations. \item{\code{id}}{(\code{character(1)})\cr Identifier for the new instance.} -\item{\code{backend}}{(\link{DataBackend})\cr -Either a \link{DataBackend}, or any object which is convertible to a -\link{DataBackend} with \code{as_data_backend()}. -E.g., am \code{sf} will be converted to a \link{DataBackendDataTable}.} +\item{\code{backend}}{(\link[mlr3:DataBackend]{mlr3::DataBackend})\cr +Either a \link[mlr3:DataBackend]{mlr3::DataBackend}, or any object which is convertible to a +\link[mlr3:DataBackend]{mlr3::DataBackend} with \code{as_data_backend()}. +E.g., am \code{sf} will be converted to a \link[mlr3:DataBackendDataTable]{mlr3::DataBackendDataTable}.} \item{\code{target}}{(\code{character(1)})\cr Name of the target column.} @@ -127,7 +128,7 @@ that the coordinates in the data are named \code{"x"} and \code{"y"}.} \item{\code{extra_args}}{(named \code{list()})\cr Named list of constructor arguments, required for converting task types -via \code{\link[=convert_task]{convert_task()}}.} +via \code{\link[mlr3:convert_task]{mlr3::convert_task()}}.} } \if{html}{\out{}} } diff --git a/man/as_task_classif_st.Rd b/man/as_task_classif_st.Rd index 1a3b6462..d5b69e07 100644 --- a/man/as_task_classif_st.Rd +++ b/man/as_task_classif_st.Rd @@ -93,10 +93,10 @@ Convert an object to a \link{TaskClassifST}. This is a S3 generic for the following objects: \enumerate{ \item \link{TaskClassifST}: Ensure the identity. -\item \code{\link[=data.frame]{data.frame()}} and \link{DataBackend}: Provides an alternative to the +\item \code{\link[=data.frame]{data.frame()}} and \link[mlr3:DataBackend]{mlr3::DataBackend}: Provides an alternative to the constructor of \link{TaskClassifST}. \item \link[sf:sf]{sf::sf}: Extracts spatial meta data before construction. -\item \link{TaskRegr}: Calls \code{\link[=convert_task]{convert_task()}}. +\item \link[mlr3:TaskRegr]{mlr3::TaskRegr}: Calls \code{\link[mlr3:convert_task]{mlr3::convert_task()}}. } } \examples{ diff --git a/man/as_task_regr_st.Rd b/man/as_task_regr_st.Rd index a64e0b3c..99e1edb2 100644 --- a/man/as_task_regr_st.Rd +++ b/man/as_task_regr_st.Rd @@ -116,10 +116,10 @@ Convert object to a \link{TaskRegrST}. This is a S3 generic, specialized for at least the following objects: \enumerate{ \item \link{TaskRegrST}: Ensure the identity. -\item \code{\link[=data.frame]{data.frame()}} and \link{DataBackend}: Provides an alternative to the +\item \code{\link[=data.frame]{data.frame()}} and \link[mlr3:DataBackend]{mlr3::DataBackend}: Provides an alternative to the constructor of \link{TaskRegrST}. \item \link[sf:sf]{sf::sf}: Extracts spatial meta data before construction. -\item \link{TaskClassif}: Calls \code{\link[=convert_task]{convert_task()}}. +\item \link[mlr3:TaskClassif]{mlr3::TaskClassif}: Calls \code{\link[mlr3:convert_task]{mlr3::convert_task()}}. } } \examples{ diff --git a/man/autoplot.ResamplingCV.Rd b/man/autoplot.ResamplingCV.Rd index bdddbde6..908dcc1b 100644 --- a/man/autoplot.ResamplingCV.Rd +++ b/man/autoplot.ResamplingCV.Rd @@ -36,8 +36,8 @@ } \arguments{ \item{object}{\verb{[Resampling]}\cr -mlr3 spatial resampling object of class \link{ResamplingCV} or -\link{ResamplingRepeatedCV}.} +mlr3 spatial resampling object of class \link[mlr3:mlr_resamplings_cv]{mlr3::ResamplingCV} or +\link[mlr3:mlr_resamplings_repeated_cv]{mlr3::ResamplingRepeatedCV}.} \item{task}{\verb{[TaskClassifST]/[TaskRegrST]}\cr mlr3 task object.} @@ -68,8 +68,8 @@ shapes.} Repetition ID to plot.} \item{x}{\verb{[Resampling]}\cr -mlr3 spatial resampling object of class \link{ResamplingCV} or -\link{ResamplingRepeatedCV}.} +mlr3 spatial resampling object of class \link[mlr3:mlr_resamplings_cv]{mlr3::ResamplingCV} or +\link[mlr3:mlr_resamplings_repeated_cv]{mlr3::ResamplingRepeatedCV}.} } \description{ Generic S3 \code{plot()} and \code{autoplot()} (ggplot2) methods. diff --git a/man/autoplot.ResamplingCustomCV.Rd b/man/autoplot.ResamplingCustomCV.Rd index 5dd01a12..e0c36d41 100644 --- a/man/autoplot.ResamplingCustomCV.Rd +++ b/man/autoplot.ResamplingCustomCV.Rd @@ -20,7 +20,7 @@ } \arguments{ \item{object}{\verb{[Resampling]}\cr -mlr3 spatial resampling object of class \link{ResamplingCustomCV}.} +mlr3 spatial resampling object of class \link[mlr3:mlr_resamplings_custom_cv]{mlr3::ResamplingCustomCV}.} \item{task}{\verb{[TaskClassifST]/[TaskRegrST]}\cr mlr3 task object.} @@ -48,7 +48,7 @@ reduce overplotting in dense datasets.} shapes.} \item{x}{\verb{[Resampling]}\cr -mlr3 spatial resampling object of class \link{ResamplingCustomCV}.} +mlr3 spatial resampling object of class \link[mlr3:mlr_resamplings_custom_cv]{mlr3::ResamplingCustomCV}.} } \description{ Generic S3 \code{plot()} and \code{autoplot()} (ggplot2) methods. diff --git a/man/autoplot.ResamplingSpCVBlock.Rd b/man/autoplot.ResamplingSpCVBlock.Rd index 23c3b75e..a242b324 100644 --- a/man/autoplot.ResamplingSpCVBlock.Rd +++ b/man/autoplot.ResamplingSpCVBlock.Rd @@ -87,7 +87,7 @@ mlr3 spatial resampling object. One of class \link{ResamplingSpCVBuffer}, \link{ResamplingSpCVBlock}, \link{ResamplingSpCVCoords}, \link{ResamplingSpCVEnv}.} } \value{ -\code{\link[=ggplot]{ggplot()}} or list of ggplot2 objects. +\code{\link[ggplot2:ggplot]{ggplot2::ggplot()}} or list of ggplot2 objects. } \description{ Generic S3 \code{plot()} and \code{autoplot()} (ggplot2) methods to diff --git a/man/mlr3spatiotempcv-package.Rd b/man/mlr3spatiotempcv-package.Rd index 4f33d04d..dfe21f45 100644 --- a/man/mlr3spatiotempcv-package.Rd +++ b/man/mlr3spatiotempcv-package.Rd @@ -6,7 +6,7 @@ \alias{mlr3spatiotempcv-package} \title{mlr3spatiotempcv: Spatiotemporal Resampling Methods for 'mlr3'} \description{ -Extends the mlr3 ML framework with spatio-temporal resampling methods to account for the presence of spatiotemporal autocorrelation (STAC) in predictor variables. STAC may cause highly biased performance estimates in cross-validation if ignored. +Extends the mlr3 machine learning framework with spatio-temporal resampling methods to account for the presence of spatiotemporal autocorrelation (STAC) in predictor variables. STAC may cause highly biased performance estimates in cross-validation if ignored. A JSS article is available at \doi{10.18637/jss.v111.i07}. } \section{Main resources}{ diff --git a/man/mlr_resamplings_repeated_spcv_block.Rd b/man/mlr_resamplings_repeated_spcv_block.Rd index 79913590..6411f78f 100644 --- a/man/mlr_resamplings_repeated_spcv_block.Rd +++ b/man/mlr_resamplings_repeated_spcv_block.Rd @@ -218,7 +218,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_repeated_spcv_coords.Rd b/man/mlr_resamplings_repeated_spcv_coords.Rd index 15140c94..04d4bb51 100644 --- a/man/mlr_resamplings_repeated_spcv_coords.Rd +++ b/man/mlr_resamplings_repeated_spcv_coords.Rd @@ -156,7 +156,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_repeated_spcv_disc.Rd b/man/mlr_resamplings_repeated_spcv_disc.Rd index 1437cd19..5ed18b04 100644 --- a/man/mlr_resamplings_repeated_spcv_disc.Rd +++ b/man/mlr_resamplings_repeated_spcv_disc.Rd @@ -148,7 +148,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_repeated_spcv_env.Rd b/man/mlr_resamplings_repeated_spcv_env.Rd index 30b7ea1d..5cda463e 100644 --- a/man/mlr_resamplings_repeated_spcv_env.Rd +++ b/man/mlr_resamplings_repeated_spcv_env.Rd @@ -161,7 +161,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_repeated_spcv_knndm.Rd b/man/mlr_resamplings_repeated_spcv_knndm.Rd index c1616f2b..3ecdc309 100644 --- a/man/mlr_resamplings_repeated_spcv_knndm.Rd +++ b/man/mlr_resamplings_repeated_spcv_knndm.Rd @@ -27,20 +27,28 @@ In order to select between clustering algorithms and number of folds `k`, differ and compared, being the one with a lower W statistic the one that offers a better match. W statistics between `knndm` runs are comparable as long as `tpoints` and `predpoints` or `modeldomain` stay the same. -Map validation using knndm should be used using `CAST::global_validation`, i.e. by stacking all out-of-sample +Map validation using `knndm` should be used using `CAST::global_validation`, i.e. by stacking all out-of-sample predictions and evaluating them all at once. The reasons behind this are 1) The resulting folds can be unbalanced and 2) nearest neighbour functions are constructed and matched using all CV folds simultaneously. -If training data points are very clustered with respect to the prediction area and the presented knndm +If training data points are very clustered with respect to the prediction area and the presented `knndm` configuration still show signs of Gj* > Gij, there are several things that can be tried. First, increase the `maxp` parameter; this may help to control for strong clustering (at the cost of having unbalanced folds). Secondly, decrease the number of final folds `k`, which may help to have larger clusters. -The `modeldomain` is a sf polygon that defines the prediction area. The function takes a regular point sample -(amount defined by `samplesize`) from the spatial extent. As an alternative use `predpoints` instead of -`modeldomain`, if you have already defined the prediction locations (e.g. raster pixel centroids). -When using either `modeldomain` or `predpoints`, we advise to plot the study area polygon and the -training/prediction points as a previous step to ensure they are aligned. +The `modeldomain` is either a sf polygon that defines the prediction area, or alternatively a SpatRaster out of which a polygon, +transformed into the CRS of the training points, is defined as the outline of all non-NA cells. +Then, the function takes a regular point sample (amount defined by `samplesize`) from the spatial extent. +As an alternative use `predpoints` instead of `modeldomain`, if you have already defined the prediction locations (e.g. raster pixel centroids). +When using either `modeldomain` or `predpoints`, we advise to plot the study area polygon and the training/prediction points as a previous step to ensure they are aligned. + +`knndm` can also be performed in the feature space by setting `space` to "feature". +Euclidean distances or Mahalanobis distances can be used for distance calculation, but only Euclidean are tested. +In this case, nearest neighbour distances are calculated in n-dimensional feature space rather than in geographical space. +`tpoints` and `predpoints` can be data frames or sf objects containing the values of the features. Note that the names of `tpoints` and `predpoints` must be the same. +`predpoints` can also be missing, if `modeldomain` is of class SpatRaster. In this case, the values of of the SpatRaster will be extracted to the `predpoints`. +In the case of any categorical features, Gower distances will be used to calculate the Nearest Neighbour distances [Experimental]. If categorical +features are present, and `clustering` = "kmeans", K-Prototype clustering will be performed instead. } \section{Parameters}{ @@ -187,7 +195,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_repeated_spcv_tiles.Rd b/man/mlr_resamplings_repeated_spcv_tiles.Rd index e59ed91d..875718dc 100644 --- a/man/mlr_resamplings_repeated_spcv_tiles.Rd +++ b/man/mlr_resamplings_repeated_spcv_tiles.Rd @@ -204,7 +204,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_repeated_sptcv_cstf.Rd b/man/mlr_resamplings_repeated_sptcv_cstf.Rd index c105e1c0..e273f584 100644 --- a/man/mlr_resamplings_repeated_sptcv_cstf.Rd +++ b/man/mlr_resamplings_repeated_sptcv_cstf.Rd @@ -166,7 +166,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_spcv_block.Rd b/man/mlr_resamplings_spcv_block.Rd index 3f11f60f..25aebb8d 100644 --- a/man/mlr_resamplings_spcv_block.Rd +++ b/man/mlr_resamplings_spcv_block.Rd @@ -166,7 +166,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_spcv_buffer.Rd b/man/mlr_resamplings_spcv_buffer.Rd index 9fc35f84..ee0b812c 100644 --- a/man/mlr_resamplings_spcv_buffer.Rd +++ b/man/mlr_resamplings_spcv_buffer.Rd @@ -141,7 +141,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_spcv_coords.Rd b/man/mlr_resamplings_spcv_coords.Rd index 6b0ec38f..271c669e 100644 --- a/man/mlr_resamplings_spcv_coords.Rd +++ b/man/mlr_resamplings_spcv_coords.Rd @@ -108,7 +108,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_spcv_disc.Rd b/man/mlr_resamplings_spcv_disc.Rd index 06f1fd3f..7393885c 100644 --- a/man/mlr_resamplings_spcv_disc.Rd +++ b/man/mlr_resamplings_spcv_disc.Rd @@ -114,7 +114,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_spcv_env.Rd b/man/mlr_resamplings_spcv_env.Rd index c132cd0c..ef696048 100644 --- a/man/mlr_resamplings_spcv_env.Rd +++ b/man/mlr_resamplings_spcv_env.Rd @@ -117,7 +117,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_spcv_knndm.Rd b/man/mlr_resamplings_spcv_knndm.Rd index 6097983a..c2f36fff 100644 --- a/man/mlr_resamplings_spcv_knndm.Rd +++ b/man/mlr_resamplings_spcv_knndm.Rd @@ -27,20 +27,28 @@ In order to select between clustering algorithms and number of folds `k`, differ and compared, being the one with a lower W statistic the one that offers a better match. W statistics between `knndm` runs are comparable as long as `tpoints` and `predpoints` or `modeldomain` stay the same. -Map validation using knndm should be used using `CAST::global_validation`, i.e. by stacking all out-of-sample +Map validation using `knndm` should be used using `CAST::global_validation`, i.e. by stacking all out-of-sample predictions and evaluating them all at once. The reasons behind this are 1) The resulting folds can be unbalanced and 2) nearest neighbour functions are constructed and matched using all CV folds simultaneously. -If training data points are very clustered with respect to the prediction area and the presented knndm +If training data points are very clustered with respect to the prediction area and the presented `knndm` configuration still show signs of Gj* > Gij, there are several things that can be tried. First, increase the `maxp` parameter; this may help to control for strong clustering (at the cost of having unbalanced folds). Secondly, decrease the number of final folds `k`, which may help to have larger clusters. -The `modeldomain` is a sf polygon that defines the prediction area. The function takes a regular point sample -(amount defined by `samplesize`) from the spatial extent. As an alternative use `predpoints` instead of -`modeldomain`, if you have already defined the prediction locations (e.g. raster pixel centroids). -When using either `modeldomain` or `predpoints`, we advise to plot the study area polygon and the -training/prediction points as a previous step to ensure they are aligned. +The `modeldomain` is either a sf polygon that defines the prediction area, or alternatively a SpatRaster out of which a polygon, +transformed into the CRS of the training points, is defined as the outline of all non-NA cells. +Then, the function takes a regular point sample (amount defined by `samplesize`) from the spatial extent. +As an alternative use `predpoints` instead of `modeldomain`, if you have already defined the prediction locations (e.g. raster pixel centroids). +When using either `modeldomain` or `predpoints`, we advise to plot the study area polygon and the training/prediction points as a previous step to ensure they are aligned. + +`knndm` can also be performed in the feature space by setting `space` to "feature". +Euclidean distances or Mahalanobis distances can be used for distance calculation, but only Euclidean are tested. +In this case, nearest neighbour distances are calculated in n-dimensional feature space rather than in geographical space. +`tpoints` and `predpoints` can be data frames or sf objects containing the values of the features. Note that the names of `tpoints` and `predpoints` must be the same. +`predpoints` can also be missing, if `modeldomain` is of class SpatRaster. In this case, the values of of the SpatRaster will be extracted to the `predpoints`. +In the case of any categorical features, Gower distances will be used to calculate the Nearest Neighbour distances [Experimental]. If categorical +features are present, and `clustering` = "kmeans", K-Prototype clustering will be performed instead. } \section{Parameters}{ @@ -143,7 +151,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_spcv_tiles.Rd b/man/mlr_resamplings_spcv_tiles.Rd index ad506e3e..c14fea45 100644 --- a/man/mlr_resamplings_spcv_tiles.Rd +++ b/man/mlr_resamplings_spcv_tiles.Rd @@ -153,7 +153,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_resamplings_sptcv_cstf.Rd b/man/mlr_resamplings_sptcv_cstf.Rd index df41ac07..551c3393 100644 --- a/man/mlr_resamplings_sptcv_cstf.Rd +++ b/man/mlr_resamplings_sptcv_cstf.Rd @@ -122,7 +122,7 @@ Materializes fixed training and test splits for a given task. \subsection{Arguments}{ \if{html}{\out{
    }} \describe{ -\item{\code{task}}{\link{Task}\cr +\item{\code{task}}{\link[mlr3:Task]{mlr3::Task}\cr A task to instantiate.} } \if{html}{\out{
    }} diff --git a/man/mlr_tasks_cookfarm_mlr3.Rd b/man/mlr_tasks_cookfarm_mlr3.Rd index be4a201f..009e4e0c 100644 --- a/man/mlr_tasks_cookfarm_mlr3.Rd +++ b/man/mlr_tasks_cookfarm_mlr3.Rd @@ -6,7 +6,7 @@ \alias{cookfarm_mlr3} \title{Cookfarm Profiles Regression Task} \format{ -\link[R6:R6Class]{R6::R6Class} inheriting from \link{TaskRegr}. +\link[R6:R6Class]{R6::R6Class} inheriting from \link[mlr3:TaskRegr]{mlr3::TaskRegr}. } \usage{ data(cookfarm_mlr3) @@ -58,9 +58,9 @@ modeling the spatial and temporal variation of soil moisture in a dryland agricultural field. Submitted to Water Resources Research. } \seealso{ -\link[mlr3misc:Dictionary]{Dictionary} of \link[=Task]{Tasks}: \link{mlr_tasks} +\link[mlr3misc:Dictionary]{Dictionary} of \link[mlr3:Task]{Tasks}: \link[mlr3:mlr_tasks]{mlr3::mlr_tasks} -\code{as.data.table(mlr_tasks)} for a complete table of all (also dynamically created) \link[=Task]{Tasks}. +\code{as.data.table(mlr_tasks)} for a complete table of all (also dynamically created) \link[mlr3:Task]{Tasks}. Other Task: \code{\link{TaskClassifST}}, diff --git a/man/mlr_tasks_diplodia.Rd b/man/mlr_tasks_diplodia.Rd index d496599b..875aeb62 100644 --- a/man/mlr_tasks_diplodia.Rd +++ b/man/mlr_tasks_diplodia.Rd @@ -6,7 +6,7 @@ \alias{diplodia} \title{Diplodia Classification Task} \format{ -\link[R6:R6Class]{R6::R6Class} inheriting from \link{TaskClassif}. +\link[R6:R6Class]{R6::R6Class} inheriting from \link[mlr3:TaskClassif]{mlr3::TaskClassif}. } \usage{ data(diplodia) @@ -35,9 +35,9 @@ Schratz P, Muenchow J, Iturritxa E, Richter J, Brenning A (2019). \doi{10.1016/j.ecolmodel.2019.06.002}. } \seealso{ -\link[mlr3misc:Dictionary]{Dictionary} of \link[=Task]{Tasks}: \link{mlr_tasks} +\link[mlr3misc:Dictionary]{Dictionary} of \link[mlr3:Task]{Tasks}: \link[mlr3:mlr_tasks]{mlr3::mlr_tasks} -\code{as.data.table(mlr_tasks)} for a complete table of all (also dynamically created) \link[=Task]{Tasks}. +\code{as.data.table(mlr_tasks)} for a complete table of all (also dynamically created) \link[mlr3:Task]{Tasks}. Other Task: \code{\link{TaskClassifST}}, diff --git a/man/mlr_tasks_ecuador.Rd b/man/mlr_tasks_ecuador.Rd index e27c9347..54fefde3 100644 --- a/man/mlr_tasks_ecuador.Rd +++ b/man/mlr_tasks_ecuador.Rd @@ -6,7 +6,7 @@ \alias{ecuador} \title{Ecuador Classification Task} \format{ -\link[R6:R6Class]{R6::R6Class} inheriting from \link{TaskClassif}. +\link[R6:R6Class]{R6::R6Class} inheriting from \link[mlr3:TaskClassif]{mlr3::TaskClassif}. } \usage{ data(ecuador) @@ -33,9 +33,9 @@ rates of landslides along a humidity gradient in the tropical Andes. Geomorphology, 139-140: 271-284. } \seealso{ -\link[mlr3misc:Dictionary]{Dictionary} of \link[=Task]{Tasks}: \link{mlr_tasks} +\link[mlr3misc:Dictionary]{Dictionary} of \link[mlr3:Task]{Tasks}: \link[mlr3:mlr_tasks]{mlr3::mlr_tasks} -\code{as.data.table(mlr_tasks)} for a complete table of all (also dynamically created) \link[=Task]{Tasks}. +\code{as.data.table(mlr_tasks)} for a complete table of all (also dynamically created) \link[mlr3:Task]{Tasks}. Other Task: \code{\link{TaskClassifST}}, diff --git a/tests/testthat/_snaps/1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg b/tests/testthat/_snaps/1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg index 453763bd..9a51ee23 100644 --- a/tests/testthat/_snaps/1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg +++ b/tests/testthat/_snaps/1-autoplot/custom-cv-fold-1-2-sample-fold-n.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -143,16 +153,6 @@ Repetition 1 - - - - - - - - - - @@ -247,55 +247,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - Custom-CV - Fold 1-2 - sample_fold_n diff --git a/tests/testthat/_snaps/1-autoplot/custom-cv-fold-1-2.svg b/tests/testthat/_snaps/1-autoplot/custom-cv-fold-1-2.svg index 53306995..45bf0d5e 100644 --- a/tests/testthat/_snaps/1-autoplot/custom-cv-fold-1-2.svg +++ b/tests/testthat/_snaps/1-autoplot/custom-cv-fold-1-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -889,16 +899,6 @@ Repetition 1 - - - - - - - - - - @@ -1739,55 +1739,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - Custom-CV - Fold 1-2 diff --git a/tests/testthat/_snaps/1-autoplot/cv-fold-1-2-groups-col-role.svg b/tests/testthat/_snaps/1-autoplot/cv-fold-1-2-groups-col-role.svg index bfb67a70..99d6b3e6 100644 --- a/tests/testthat/_snaps/1-autoplot/cv-fold-1-2-groups-col-role.svg +++ b/tests/testthat/_snaps/1-autoplot/cv-fold-1-2-groups-col-role.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -889,16 +899,6 @@ Repetition 1 - - - - - - - - - - @@ -1739,55 +1739,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - CV - Fold 1,2 - groups col role diff --git a/tests/testthat/_snaps/1-autoplot/cv-fold-1-2-sample-fold-n.svg b/tests/testthat/_snaps/1-autoplot/cv-fold-1-2-sample-fold-n.svg index 86df5c64..c19ca097 100644 --- a/tests/testthat/_snaps/1-autoplot/cv-fold-1-2-sample-fold-n.svg +++ b/tests/testthat/_snaps/1-autoplot/cv-fold-1-2-sample-fold-n.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -136,16 +146,6 @@ Repetition 1 - - - - - - - - - - @@ -244,55 +244,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - CV - Fold 1-2 - sample_fold_n diff --git a/tests/testthat/_snaps/1-autoplot/cv-fold-1-2.svg b/tests/testthat/_snaps/1-autoplot/cv-fold-1-2.svg index 5797c7dc..088e1d41 100644 --- a/tests/testthat/_snaps/1-autoplot/cv-fold-1-2.svg +++ b/tests/testthat/_snaps/1-autoplot/cv-fold-1-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -160,16 +170,6 @@ Repetition 1 - - - - - - - - - - @@ -281,55 +281,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - CV - Fold 1-2 diff --git a/tests/testthat/_snaps/1-autoplot/repcv-fold-1-2-rep-1.svg b/tests/testthat/_snaps/1-autoplot/repcv-fold-1-2-rep-1.svg index 00193c65..f9c0c493 100644 --- a/tests/testthat/_snaps/1-autoplot/repcv-fold-1-2-rep-1.svg +++ b/tests/testthat/_snaps/1-autoplot/repcv-fold-1-2-rep-1.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -160,16 +170,6 @@ Repetition 1 - - - - - - - - - - @@ -281,55 +281,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - RepCV - Fold 1-2 Rep 1 diff --git a/tests/testthat/_snaps/1-autoplot/repspcvblock-fold-1-2-rep-1.svg b/tests/testthat/_snaps/1-autoplot/repspcvblock-fold-1-2-rep-1.svg index 03d74fb0..48151400 100644 --- a/tests/testthat/_snaps/1-autoplot/repspcvblock-fold-1-2-rep-1.svg +++ b/tests/testthat/_snaps/1-autoplot/repspcvblock-fold-1-2-rep-1.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -160,16 +170,6 @@ Repetition 1 - - - - - - - - - - @@ -281,55 +281,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - RepSpCVBlock - Fold 1-2 Rep 1 diff --git a/tests/testthat/_snaps/1-autoplot/repspcvcoords-fold-1-2-rep-1.svg b/tests/testthat/_snaps/1-autoplot/repspcvcoords-fold-1-2-rep-1.svg index 288a3a65..097228d2 100644 --- a/tests/testthat/_snaps/1-autoplot/repspcvcoords-fold-1-2-rep-1.svg +++ b/tests/testthat/_snaps/1-autoplot/repspcvcoords-fold-1-2-rep-1.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -160,16 +170,6 @@ Repetition 1 - - - - - - - - - - @@ -281,55 +281,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - RepSpCVCoords - Fold 1-2 Rep 1 diff --git a/tests/testthat/_snaps/1-autoplot/repspcvcoords-fold-1-2-sample-fold-n.svg b/tests/testthat/_snaps/1-autoplot/repspcvcoords-fold-1-2-sample-fold-n.svg index 8359fdb7..ce5de16e 100644 --- a/tests/testthat/_snaps/1-autoplot/repspcvcoords-fold-1-2-sample-fold-n.svg +++ b/tests/testthat/_snaps/1-autoplot/repspcvcoords-fold-1-2-sample-fold-n.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -136,16 +146,6 @@ Repetition 1 - - - - - - - - - - @@ -233,55 +233,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - RepSpCVCoords - Fold 1-2 - sample_fold_n diff --git a/tests/testthat/_snaps/1-autoplot/repspcvenv-fold-1-2-rep-1.svg b/tests/testthat/_snaps/1-autoplot/repspcvenv-fold-1-2-rep-1.svg index 92e570b6..1489ff17 100644 --- a/tests/testthat/_snaps/1-autoplot/repspcvenv-fold-1-2-rep-1.svg +++ b/tests/testthat/_snaps/1-autoplot/repspcvenv-fold-1-2-rep-1.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -160,16 +170,6 @@ Repetition 1 - - - - - - - - - - @@ -281,55 +281,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - RepSpCVEnv - Fold 1-2 Rep 1 diff --git a/tests/testthat/_snaps/1-autoplot/spcvblock-fold-1-2-sample-fold-n.svg b/tests/testthat/_snaps/1-autoplot/spcvblock-fold-1-2-sample-fold-n.svg index 6d300147..08fece63 100644 --- a/tests/testthat/_snaps/1-autoplot/spcvblock-fold-1-2-sample-fold-n.svg +++ b/tests/testthat/_snaps/1-autoplot/spcvblock-fold-1-2-sample-fold-n.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -136,16 +146,6 @@ Repetition 1 - - - - - - - - - - @@ -233,55 +233,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - SpCVBlock - Fold 1-2 - sample_fold_n diff --git a/tests/testthat/_snaps/1-autoplot/spcvblock-fold-1-2.svg b/tests/testthat/_snaps/1-autoplot/spcvblock-fold-1-2.svg index c17134d6..76b117ce 100644 --- a/tests/testthat/_snaps/1-autoplot/spcvblock-fold-1-2.svg +++ b/tests/testthat/_snaps/1-autoplot/spcvblock-fold-1-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -160,16 +170,6 @@ Repetition 1 - - - - - - - - - - @@ -281,55 +281,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - SpCVBlock - Fold 1-2 diff --git a/tests/testthat/_snaps/1-autoplot/spcvcoords-fold-1-2.svg b/tests/testthat/_snaps/1-autoplot/spcvcoords-fold-1-2.svg index 5e9b28a8..edd725eb 100644 --- a/tests/testthat/_snaps/1-autoplot/spcvcoords-fold-1-2.svg +++ b/tests/testthat/_snaps/1-autoplot/spcvcoords-fold-1-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -160,16 +170,6 @@ Repetition 1 - - - - - - - - - - @@ -281,55 +281,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - SpCVCoords - Fold 1-2 diff --git a/tests/testthat/_snaps/1-autoplot/spcvenv-fold-1-2-sample-fold-n.svg b/tests/testthat/_snaps/1-autoplot/spcvenv-fold-1-2-sample-fold-n.svg index 6a5ab76f..07ed60f8 100644 --- a/tests/testthat/_snaps/1-autoplot/spcvenv-fold-1-2-sample-fold-n.svg +++ b/tests/testthat/_snaps/1-autoplot/spcvenv-fold-1-2-sample-fold-n.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -132,16 +142,6 @@ Repetition 1 - - - - - - - - - - @@ -225,55 +225,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - SpCVEnv - Fold 1-2 - sample_fold_n diff --git a/tests/testthat/_snaps/1-autoplot/spcvenv-fold-1-2.svg b/tests/testthat/_snaps/1-autoplot/spcvenv-fold-1-2.svg index 332eeb9c..b7cf46a7 100644 --- a/tests/testthat/_snaps/1-autoplot/spcvenv-fold-1-2.svg +++ b/tests/testthat/_snaps/1-autoplot/spcvenv-fold-1-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -160,16 +170,6 @@ Repetition 1 - - - - - - - - - - @@ -281,55 +281,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - SpCVEnv - Fold 1-2 diff --git a/tests/testthat/_snaps/2-autoplot/repspcvdisc-fold-1-2-sample-fold-n.svg b/tests/testthat/_snaps/2-autoplot/repspcvdisc-fold-1-2-sample-fold-n.svg index 37a1ca13..6d80d0c6 100644 --- a/tests/testthat/_snaps/2-autoplot/repspcvdisc-fold-1-2-sample-fold-n.svg +++ b/tests/testthat/_snaps/2-autoplot/repspcvdisc-fold-1-2-sample-fold-n.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -127,16 +137,6 @@ Repetition 1 - - - - - - - - - - @@ -211,55 +211,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - RepSpCVDisc - Fold 1-2 - sample_fold_n diff --git a/tests/testthat/_snaps/2-autoplot/repspcvknndm-fold-1-2-sample-fold-n.svg b/tests/testthat/_snaps/2-autoplot/repspcvknndm-fold-1-2-sample-fold-n.svg index c4302b70..a08293f8 100644 --- a/tests/testthat/_snaps/2-autoplot/repspcvknndm-fold-1-2-sample-fold-n.svg +++ b/tests/testthat/_snaps/2-autoplot/repspcvknndm-fold-1-2-sample-fold-n.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -117,16 +127,6 @@ Repetition 1 - - - - - - - - - - @@ -180,55 +180,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - RepSpCVKnndm - Fold 1-2 - sample_fold_n diff --git a/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2-rep-2.svg b/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2-rep-2.svg index eb07fe72..d04f085e 100644 --- a/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2-rep-2.svg +++ b/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2-rep-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -821,16 +831,6 @@ Repetition 2 - - - - - - - - - - @@ -1603,55 +1603,14 @@ 2, Repetition 2 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - RepSpCVTiles - Fold 1-2, Rep 2 diff --git a/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2-sample-fold-n.svg b/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2-sample-fold-n.svg index 3974ebbb..f4b617ad 100644 --- a/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2-sample-fold-n.svg +++ b/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2-sample-fold-n.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -155,16 +165,6 @@ Repetition 1 - - - - - - - - - - @@ -276,55 +276,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - RepSpCVTiles - Fold 1-2 - sample_fold_n diff --git a/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2.svg b/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2.svg index 0d15befd..dbd1e9f7 100644 --- a/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2.svg +++ b/tests/testthat/_snaps/2-autoplot/repspcvtiles-fold-1-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -821,16 +831,6 @@ Repetition 1 - - - - - - - - - - @@ -1603,55 +1603,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - RepSpCVTiles Fold 1-2 diff --git a/tests/testthat/_snaps/2-autoplot/spcvdisc-fold-1-2.svg b/tests/testthat/_snaps/2-autoplot/spcvdisc-fold-1-2.svg index 46e48de0..527ad4a2 100644 --- a/tests/testthat/_snaps/2-autoplot/spcvdisc-fold-1-2.svg +++ b/tests/testthat/_snaps/2-autoplot/spcvdisc-fold-1-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -866,16 +876,6 @@ Repetition 1 - - - - - - - - - - @@ -1703,55 +1703,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - SpCVDisc Fold 1-2 diff --git a/tests/testthat/_snaps/2-autoplot/spcvknndm-fold-1-2.svg b/tests/testthat/_snaps/2-autoplot/spcvknndm-fold-1-2.svg index 7741aa59..246a0a82 100644 --- a/tests/testthat/_snaps/2-autoplot/spcvknndm-fold-1-2.svg +++ b/tests/testthat/_snaps/2-autoplot/spcvknndm-fold-1-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -1099,16 +1109,6 @@ Repetition 1 - - - - - - - - - - @@ -2159,55 +2159,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - SpCVKnndm Fold 1-2 diff --git a/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-space-var-fold-1-2.svg b/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-space-var-fold-1-2.svg index 43b9a812..a0285508 100644 --- a/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-space-var-fold-1-2.svg +++ b/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-space-var-fold-1-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -140,16 +150,6 @@ Repetition 1 - - - - - - - - - - @@ -231,55 +231,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - SptCVCstf 2D space_var - Fold 1-2 diff --git a/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-time-var-fold-1-2-sample-fold-n.svg b/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-time-var-fold-1-2-sample-fold-n.svg index d089feca..21c18390 100644 --- a/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-time-var-fold-1-2-sample-fold-n.svg +++ b/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-time-var-fold-1-2-sample-fold-n.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -140,16 +150,6 @@ Repetition 1 - - - - - - - - - - @@ -231,55 +231,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - SptCVCstf 2D time_var - Fold 1-2 - sample_fold_n diff --git a/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-time-var-fold-1-2.svg b/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-time-var-fold-1-2.svg index 7f186896..18d16e2d 100644 --- a/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-time-var-fold-1-2.svg +++ b/tests/testthat/_snaps/2-autoplot/sptcvcstf-2d-time-var-fold-1-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -145,16 +155,6 @@ Repetition 1 - - - - - - - - - - @@ -246,55 +246,14 @@ 2, Repetition 1 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - SptCVCstf 2D time_var - Fold 1-2 diff --git a/tests/testthat/_snaps/autoplot_buffer/spcvbuffer-fold-1-2.svg b/tests/testthat/_snaps/autoplot_buffer/spcvbuffer-fold-1-2.svg index e43b4af7..eb2fbfe5 100644 --- a/tests/testthat/_snaps/autoplot_buffer/spcvbuffer-fold-1-2.svg +++ b/tests/testthat/_snaps/autoplot_buffer/spcvbuffer-fold-1-2.svg @@ -48,6 +48,16 @@ + + + + + + + + + + @@ -153,16 +163,6 @@ Fold 1 - - - - - - - - - - @@ -265,55 +265,14 @@ Fold 2 - - - - - - - - - - - - - Set - - - - - - - - - - - - - - - - - - - - Train - - - - Test - - - - SpCVBuffer - Fold 1-2 diff --git a/tests/testthat/test-TaskClassifST.R b/tests/testthat/test-TaskClassifST.R index d1bbd55c..088da22b 100644 --- a/tests/testthat/test-TaskClassifST.R +++ b/tests/testthat/test-TaskClassifST.R @@ -14,7 +14,7 @@ test_that("printing works", { test_that("Supplying a non-spatio temporal task gives descriptive error message", { expect_error( - rsmp("spcv_coords")$instantiate(tsk("boston_housing")), + rsmp("spcv_coords")$instantiate(tsk("mtcars")), "Must inherit from class 'TaskClassifST' or 'TaskRegrST'." ) # nolint })