<jupyter_start><jupyter_text>Support Vector Machines  HyperparametersWhen we define the model, we can specify the hyperparameters.- C: The C parameter.- kernel: The kernel. The most common ones are 'linear', 'poly', and 'rbf'.- degree: If the kernel is polynomial, this is the maximum degree of the monomials in the kernel.- gamma : If the kernel is rbf, this is the gamma parameter.For example, here we define a model with a polynomial kernel of degree 4, and a C parameter of 0.1.*'model = SVC(kernel='poly', degree=4, C=0.1)'*  Example:<jupyter_code># Import statements 
from sklearn.svm import SVC
from sklearn.metrics import accuracy_score
import pandas as pd
import numpy as np

# Read the data.
data = pd.read_csv('csv_files/data2.csv')

# Assign the features to the variable X, and the labels to the variable y. 
X = np.array(data[['x1', 'x2']])
y = np.array(data['y'])

# TODO: Create the model and assign it to the variable model.
# Find the right parameters for this model to achieve 100% accuracy on the dataset.
model = SVC(kernel='rbf', gamma=27)

# TODO: Fit the model.
model.fit(X, y)

# TODO: Make predictions. Store them in the variable y_pred.
y_pred = model.predict(X)

# TODO: Calculate the accuracy and assign it to the variable acc.
acc = accuracy_score(y, y_pred)

# Print Accuracy
print('Accuracy is: ', acc)<jupyter_output>Accuracy is:  1.0
{'fraction_non_alphanumeric': 0.09882869692532943, 'fraction_numerical': 0.01171303074670571, 'mean_word_length': 4.512096774193548, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '225790', 'license': 'MIT', 'n_tokens_mistral': 439, 'n_tokens_neox': 421, 'n_words': 188, 'path': 'Supervised-Learning/support_vector_machine.ipynb', 'repo_name': 'carlosmertens/Learning-Training', 'size': '1366'}