import pandas as pd
import numpy as np
from sklearn.model_selection import train_test_split
from sklearn.metrics import accuracy_score
from sklearn.svm import SVC

names = ['Sample', 'Clump Thickness','Uniformity of Cell Size','Uniformity of Cell Shape','Marginal Adhesion','Single Epithelial Cell Size','Bare Nuclei','Bland Chromatin', 'Normal Nucleoli', 'Mitoses', 'class']

df = pd.read_csv('breast.data.csv', header=None, names=names)
X = np.array(df.iloc[:, 1:10]) 	
y = np.array(df['class'])

# split the data into the train and test sets
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.30)

model = SVC(gamma='auto').fit(X_train, y_train)
pred = model.predict(X_test)

print ('\nModel accuracy score: ', accuracy_score(y_test, pred))
    