Skip to content

Instantly share code, notes, and snippets.

@aniruddha27
Last active April 9, 2020 12:52
Show Gist options
  • Save aniruddha27/0207c15e391c81bb185e290363da2de4 to your computer and use it in GitHub Desktop.
Save aniruddha27/0207c15e391c81bb185e290363da2de4 to your computer and use it in GitHub Desktop.
# matplotlib
import matplotlib.pyplot as plt
plt.style.use('seaborn')
# plot roc curves
plt.plot(fpr1, tpr1, linestyle='--',color='orange', label='Logistic Regression')
plt.plot(fpr2, tpr2, linestyle='--',color='green', label='KNN')
plt.plot(p_fpr, p_tpr, linestyle='--', color='blue')
# title
plt.title('ROC curve')
# x label
plt.xlabel('False Positive Rate')
# y label
plt.ylabel('True Positive rate')
plt.legend(loc='best')
plt.savefig('ROC',dpi=300)
plt.show();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment