This function creates the assignments to perform a stratified crossvalidation. It requires, for each element of the set, a label describing the strata it belongs to. It also requires the number of folds.
stratified_crossvalidation_folds(strata, folds.num)an array, same length as strata, of numbers in the 1:folds.num set
an array of strata (will be treated as a factor)
the number of folds
A warning is triggered if the number of folds is greater than the number of elements of any stratum.