train_test_split
TensorFlow Tutorial— Part 1
Illia Polosukhin
18519

It would be nice if this page were self-contained, instead of having to read the source code (titanic.py) in parallel. To make it so, you just need to add a few imports:

>>> from sklearn.linear_model import LogisticRegression
>>> from sklearn.metrics import accuracy_score
>>> from sklearn.cross_validation import train_test_split