Python, Data Science, Machine Learning, Technology, Finance.
y_val = train_test_split(X_train_val, y_train_val, test_size=0.25, random_state=42) svc = SVC() svc.fit(X_train, y_train) y_pred_val = svc.predict(X_val) The important thing to note here is the predict() function, let’s predict a specific (first) record. print(svc.predict(X_val.loc[[1]]))