[text] split

Viewer

  1. from sklearn.model_selection import train_test_split
  2.  
  3. X = df.iloc[:, 0:11]
  4. y = df.iloc[:, -1]
  5. X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2, random_state=4)

Editor

You can edit this paste and save as new:


File Description
  • split
  • Paste Code
  • 04 May-2024
  • 186 Bytes
You can Share it: