python - Reduce space between first histogram bar and y-axis -


I have a histogram that I have created using the following:

  import = Frakdist (list (industry)) x = np range (lane (fd) pl.bar (x, fd. Value,), align = 'center', width = 0.15) as pylab pl fd. Xticks (x, fd.kiz), rotation = 90) pl.tick_params (labelsize = 8) ymax = max (fd.values ​​()) + 1 pl.ylim (0, ymax) pl.subplots_adjust (below = 0.3) pl.savefig ('internalDoorCount .jpg')  

Although I have the y-axis and the histogram bar first There is a need to reduce the difference between the two. How do you prevent text from overlapping?

You can try to avoid overlapping text by using this function:

pl.gcf (). Autofmt_xdate (below = 0.3, rotation = -30, HA = "left")

It is designed to rotate the date mark label, but it should work well here. But you probably have to reduce the maximum font size, and / or increase the width of your shape.


Comments

Popular posts from this blog

ios - How do I use CFArrayRef in Swift? -

eclipse plugin - Run java code error: Workspace is closed -

c - Error on building source code in VC 6 -