ROC Curve and AUC value of SVM model

I am new to ML. I have a question so I am evaluating my SVM model.

Example:

SVM_MODEL = svm.SVC()
SVM_MODEL.fit(X_train,y_train)
SVM_OUTPUT = SVM_MODEL.predict(X_test)


And I want to plot my roc curve and AUC value for it is this the correct code?

fpr1, tpr1, thresholds = metrics.roc_curve(y_valid, SVM_OUTPUT, pos_label=0)
plt.ylabel(“True Positive Rate”)
plt.xlabel(“False Positive Rate”)
plt.title(“ROC Curve”)
plt.plot(tpr1,fpr1)
plt.show()
auc = np.trapz(fpr1,tpr1)
print(‘Area Under ROC Curve:’, auc)


from sklearn.metrics import plot_precision_recall_curve

• I gave you exactly how you plot it with an example just click on the link and read the first sentence. plot_roc_curve(model,X_test,y_test) it cant get any easier. – ombk Nov 24 '20 at 0:24