Kfold {MLInterfaces} | R Documentation

## for given n, generate a K-fold partition of 1:n

### Description

for given n, generate a K-fold partition of 1:n

### Usage

    Kfold(n, K=5)

### Arguments

`n` | number of elements to be partitioned
`K` | number of partitions

### Value

a vector of length n with elements 1:K, as balanced as possible, sorted increasing

### Author(s)

Vince Carey <stvjc@channing.harvard.edu>

### Examples

    Kfold(23)

[Package MLInterfaces version 1.12.0 Index]