Skip to content

Glossary: ML Basics

train_test_split

A scikit-learn function that shuffles rows and returns X_train, X_test, y_train and y_test. test_size sets the held-back share.

Where the book teaches it

Related terms

Training setTest setStratifiedrandom_state