The problem is connected with the matplotlib bar chart. To be specific, when I draw a bar chart some of the bars are not visible.
Dots and bars uses the same data series so should be in the same places
.
I do not know what is the source of this problem that is why I am posting this question. I have also noticed that for the same plot, when I enlarge the window to the full screen the missing bars magically appears
The same data series as in the first picture, just full screen window
.
The same happens also when I change the color of the plot, so lets say I use:
artist = plot.bar(x_data_series, y_data_series, color="black")
Right now I have this not complete chart, but when I use (just setting the color for the second time right after):
artist = plot.bar(x_data_series, y_data_series, color="black")
matplotlib.artist.setp(artist, color="black")
I get this:
Now all bars are visible
.
The same happens when I zoom in this incomplete chart:
Here also all bars are visible
.
What is more the "invisible bars", when they are visible, they seem to be a little bit thicker than the others, however they width in the artist properties is the same as you can see here:
One of this bars is the thicker one and the other the "normal" one, both are 0.8 in width
.
Just to give you more information this is a graph embedded in the tkinter. Here are the figure, canvas, and axes (parent frame is just a frame in which the plot is placed):
figure = Figure(dpi=100)
plot = figure.add_subplot(111)
canvas = FigureCanvasTkAgg(figure, parent_frame)
The "work arounds" I have found are not satisfactory for me and I would really like to find the source of the problem, plus the width problem is something I can't figure out.