blockCV: Spatial and Environmental Blocking for K-Fold and LOO Cross-Validation

Creating spatially or environmentally separated folds for cross-validation to provide a robust error estimation in spatially structured environments; Investigating and visualising the effective range of spatial autocorrelation in continuous raster covariates and point samples to find an initial realistic distance band to separate training and testing datasets spatially described in Valavi, R. et al. (2019) <doi:10.1111/2041-210X.13107>.

Version: 3.1-4
Depends: R (≥ 3.5.0)
Imports: sf (≥ 1.0), Rcpp (≥ 1.0.2)
LinkingTo: Rcpp
Suggests: terra (≥ 1.6-41), ggplot2 (≥ 3.3.6), cowplot, automap (≥ 1.0-16), shiny (≥ 1.7), tmap (≥ 2.0), biomod2, gstat, methods, knitr, rmarkdown, testthat (≥ 3.0.0), covr
Published: 2024-05-23
DOI: 10.32614/CRAN.package.blockCV
Author: Roozbeh Valavi ORCID iD [aut, cre], Jane Elith [aut], José Lahoz-Monfort [aut], Ian Flint [aut], Gurutzeta Guillera-Arroita [aut]
Maintainer: Roozbeh Valavi <valavi.r at>
License: GPL (≥ 3)
NeedsCompilation: yes
Citation: blockCV citation info
CRAN checks: blockCV results


Reference manual: blockCV.pdf
Vignettes: 1. blockCV introduction: how to create block cross-validation folds
2. Block cross-validation for species distribution modelling


Package source: blockCV_3.1-4.tar.gz
Windows binaries: r-devel:, r-release:, r-oldrel:
macOS binaries: r-release (arm64): blockCV_3.1-4.tgz, r-oldrel (arm64): blockCV_3.1-4.tgz, r-release (x86_64): blockCV_3.1-4.tgz, r-oldrel (x86_64): blockCV_3.1-4.tgz
Old sources: blockCV archive

Reverse dependencies:

Reverse imports: forestecology, PointedSDMs
Reverse suggests: BiodiversityR, confcons, ENMeval, mlr3spatiotempcv, tidysdm


Please use the canonical form to link to this page.