Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #we'll have to split our data into two, 67% of our data to train and 33% to test
- array = data.values
- X = array[:,0:8]
- Y = array[:,8]
- test_size = 0.33
- seed = 7
- #spliting the dataset
- X_train, X_test, Y_train, Y_test = train_test_split(X, Y, test_size=test_size,
- random_state=seed)
- #giving our algorith LogisticRegression a variable name
- model = LogisticRegression()
- #Training our model
- model.fit(X_train, Y_train)
Add Comment
Please, Sign In to add comment