Untitled

mail@pastecode.io avatar
unknown
plain_text
2 years ago
610 B
20
Indexable
Never
#Split dataset into train and test
from sklearn.model_selection import train_test_split
X_train, X_test, y_train, y_test = train_test_split(
                                                                          X,
                                                                          y,
                                                                          test_size=0.25,
                                                                          random_state=1,
                                                                          shuffle=True

)
print(X_train.shape, y_train.shape)