I am trying to choose a method to split my data into train and test sets. I am currently using Scikit's RepeatedStratifiedKFold. According to the documentation, the RepeatedStratifiedKFold is a:
Repeated Stratified K-Fold cross validator.
Repeats Stratified K-Fold
ntimes with different randomization in each repetition.
I use the RepeatedStratifiedKFold using 5 folds and 100 repetitions on a dataset consisting of 1000 observations as follows:
rskf = RepeatedStratifiedKFold(n_splits=5, n_repeats=100, random_state=None)
for train_index, test_index in rskf.split(X, y):
X_train, _X_test = X[train_index], X[test_index]
y_train, y_test = y[train_index], y[test_index]
However, when I look at the X_train set, I only see 800 observations (4 train folds). Shouldn't it contain all 100 train sets as per the number of repetitions?
My second question: after splitting your data using the RepeatedStratifiedKFold method, what happens when you fit your classification model on the X_train and y_train datasets? Does the model train on all 100 repetitions?
Suppose I just wanted the F1-score from the model after testing it. Does it give me the average score across all 100 repetitions?
Thanks!