powered by
Check the balance of presences vs pseudoabsences among splits
check_splits_balance(splits, .col)
a tibble of the number of presences and pseudoabsences in the assessment and analysis set of each split (or training and testing in an initial split)
the data splits (an rset or split object), generated by a function such as spatialsample::spatial_block_cv()
rset
split
spatialsample::spatial_block_cv()
the column containing the presences
lacerta_thin <- readRDS(system.file("extdata/lacerta_thin_all_vars.rds", package = "tidysdm" )) lacerta_cv <- spatial_block_cv(lacerta_thin, v = 5) check_splits_balance(lacerta_cv, class)
Run the code above in your browser using DataLab