Session Ready
Exercise

Using a pipeline

Now that you have our pipeline defined, aka combining a logistic regression with a SMOTE method, let's run it on the data. You can treat the pipeline as if it were a single machine learning model. Our data X and y are already defined, and the pipeline is defined in the previous exercise. Are you curious to find out what the model results are? Let's give it a try!

Instructions
100 XP
  • Split the data 'X'and 'y' into the training and test set. Set aside 30% of the data for a test set, and set the random_state to zero.
  • Fit your pipeline onto your training data and obtain the predictions by running the pipeline.predict() function on our X_test dataset.