From 183738e96f86ca46921594537c4041a9a3cd006e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?K=C3=BChle=2C=20Laura=20Christine=20=28lakue103=29?=
 <laura.kuehle@uni-duesseldorf.de>
Date: Fri, 20 Aug 2021 17:21:44 +0200
Subject: [PATCH] Fixed bug for ticks in bar plot.

---
 Plotting.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/Plotting.py b/Plotting.py
index 2fa5fdb..aaac2b5 100644
--- a/Plotting.py
+++ b/Plotting.py
@@ -3,6 +3,7 @@
 @author: Laura C. Kühle
 
 TODO: Give option to select plotting color
+TODO: Fix bug for ticks in bar plot -> Done
 
 """
 import numpy as np
@@ -127,7 +128,7 @@ def plot_classification_accuracy(precision, recall, accuracy, xlabels):
     ax.bar(pos - width, precision, width, label='Precision')
     ax.bar(pos, recall, width, label='Recall')
     ax.bar(pos + width, accuracy, width, label='Accuracy')
-    ax.set_xticks(x)
+    ax.set_xticks(pos)
     ax.set_xticklabels(xlabels)
     ax.set_ylabel('Classification (%)')
     ax.set_ylim(bottom=0.6)
@@ -135,4 +136,3 @@ def plot_classification_accuracy(precision, recall, accuracy, xlabels):
     ax.set_title('Non-Normalized Test Data')
     ax.legend(loc='upper right')
     # fig.tight_layout()
-    fig.savefig('TestAdamPrecisionRecallAccuracy.pdf')
-- 
GitLab