python - Randomized stratified k-fold cross-validation in scikit-learn? -
is there built-in way scikit-learn perform shuffled stratified k-fold cross-validation? 1 of common cv methods, , surprised couldn't find built-in method this.
i saw cross_validation.kfold()
has shuffling flag, not stratified. unfortunately cross_validation.stratifiedkfold()
not have such option, , cross_validation.stratifiedshufflesplit()
not produce disjoint folds.
am missing something? planned?
(obviously can implement myself)
the shuffling flag cross_validation.stratifiedkfold
has been introduced in current version 0.15:
http://scikit-learn.org/0.15/modules/generated/sklearn.cross_validation.stratifiedkfold.html
this can found in changelog:
http://scikit-learn.org/stable/whats_new.html#new-features
shuffle option cross_validation.stratifiedkfold. jeffrey blackburne.
Comments
Post a Comment