0

I'm trying to add values of the confusion matrix I made by my self.

Confusion matrix

This is my code:

import numpy as np
import matplotlib.pyplot as plt
metrics = np.random.randint(0, 50, (2,2))
ax = fig.add_subplot(111)
cax = ax.matshow(metrics)
plt.title(f'consusion matrix')
fig.colorbar(cax)
plt.xlabel('Predicted')
plt.ylabel('True')
plt.show()
desertnaut
  • 57,590
  • 26
  • 140
  • 166
juanmac
  • 121
  • 1
  • 12

0 Answers0