Machine Learning, Data Science, Data Scientist, Mlops, Algorithms.
y_train, y_test = train_test_split(X, y, test_size=0.2, random_state=42) # Creating and training the Naive Bayes model model = GaussianNB() model.fit(X_train, y_train) # Predicting the test set results y_pred = model.predict(X_test) # Evaluating the model accuracy = accuracy_score(y_test, y_pred)