Description Usage Arguments Value
View source: R/kfold_partition.R
Randomly partition sites into groups for cross-validation.
Sites are randomly partitioned into K groups that are
roughly similar in size (i.e., number of observations). If multiple permutations
are requested, kfold_partition
returns the one with the smallest range
of group sizes.
1 | kfold_partition(psm_dat, K, N_random = 1000)
|
psm_dat |
A data frame with a column of class factor named |
K |
A positive integer giving the number of groups. |
N_random |
A natural number giving the number of random permutations to compare. |
A named list with components
N_group
A vector of group sizes.
A vector giving the group membership of each row in psm_dat
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.