Question 4 Using train_test_split, split x and y into training and test sets (x_train, x_test, y_train, and y_test). Set the random number generator state to 0 using random_state=0 to make sure your results match the autograder! This function should return a tuple of length 4: (x_train, x_test, y_train, y_test), where •x_train has shape (426, 30) x_test has shape (143, 30) y_train has shape (426,) • y_test has shape (143,) from sklearn.model_selection import train_test_split def answer four (): #YOUR CODE HERE raise NotImplementedError()
Question 4 Using train_test_split, split x and y into training and test sets (x_train, x_test, y_train, and y_test). Set the random number generator state to 0 using random_state=0 to make sure your results match the autograder! This function should return a tuple of length 4: (x_train, x_test, y_train, y_test), where •x_train has shape (426, 30) x_test has shape (143, 30) y_train has shape (426,) • y_test has shape (143,) from sklearn.model_selection import train_test_split def answer four (): #YOUR CODE HERE raise NotImplementedError()
Related questions
Question
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by step
Solved in 3 steps with 1 images