This tutorial demonstrates how to generate stratified folds from your dataset. Stratification is extremely important for cross validation where you need to create X number of folds from your dataset and the data distribution in each fold should be close to that in the entire dataset.
For more information on stratification: http://en.wikipedia.org/wiki/Stratified_sampling
آی-ویدئو