Currently there is no easy way to set specific colors for specific bars in matplotlib if you are using the object oriented method.
This leads to my second question which is what is the best way to plot in matplotlib (the pyplot one or the oop one)?
One hack I found:
heights = x
labels = y
colors = ["dimgrey" for x in labels]
if np.isin(true_val, labels):
index = np.argmax(labels == true_val)
colors[index] = "green"
ax[3].bar(labels, heights, color=colors)
Pyplot way:
barlist=plt.bar([1,2,3,4], [1,2,3,4])
barlist[0].set_color('r')
Similar Questions: