Add k-fold partitioning for cross validation.