I need some help in switching the position of the confusion matrix as shown in the image below.
.
The code below is the current version whereby the true positive is at the bottom right. Appreciate the help. Thanks in advance.
from sklearn.metrics import confusion_matrix
#data_swn['Truth'] = data_swn['Truth'].astype(str)
cf_matrix3 = confusion_matrix(data_swn['SWN_Sentiment'], data_swn['Truth'])
cf_matrix3
labels = ['True Neg','False Pos','False Neg','True Pos']
Group_percentages = ['{0:.2%}'.format(value) for value in cf_matrix1.flatten() / np.sum(cf_matrix1)]
labels = [f'{v1}\n{v2}' for v1, v2 in zip(labels,Group_percentages)]
labels = np.asarray(labels).reshape(2,2)
ax = sns.heatmap(cf_matrix1, annot=labels, fmt='', cmap='Blues')
ax.set_title('Seaborn Confusion Matrix with labels\n\n');
ax.set_xlabel('\nPredicted Values')
ax.set_ylabel('Actual Values ');
## Ticket labels - List must be in alphabetical order
ax.xaxis.set_ticklabels(['False','True'])
ax.yaxis.set_ticklabels(['False','True'])
## Display the visualization of the Confusion Matrix.
plt.show()

