a guest Jun 18th, 2019 43 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. def execute_pipeline(features,target)
  2.   '''
  3.   Takes in features(X) and target(y) and performs a grid search
  4.   by Logistic Regression, SVM, and Random Forest.
  5.   '''
  6.   import numpy as np
  7.   from scipy.stats import uniform
  8.   from sklearn.linear_model import LogisticRegression
  9.   from sklearn.model_selection import GridSearchCV
  10.   from sklearn.pipeline import Pipeline, FeatureUnion
  11.   from sklearn.decomposition import PCA
  12.   from sklearn.preprocessing import StandardScaler
  13.   from sklearn.svm import SVC
  14.   from sklearn.ensemble import RandomForestClassifier
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand