0

I have created a 4 rows x 2 columns plot in python. The height space hspace reduces the vertical spacing between subplots which is fine but when I reduce the wspace thinking it is the horizontal space , it simply doesn't work. The tight layout is also not working.

This figure is 30x30 in size

fig, (ax1, ax2, ax3, ax4) = plt.subplots(4,2,figsize=(30,30))
fig.tight_layout()

The Space is orange is what I want to reduce or remove Reduce the orange area space

Please help :)

user199663
  • 11
  • 1
  • You are probably drawing images with the default `aspect='equal'`. Maybe you can use `aspect='auto'`? Otherwise, you'll need to choose a narrower figsize. You either need to lose control about the whitespace or about having unstretched images. Note that your question is missing a lot of code to be reproducible. – JohanC Mar 09 '22 at 00:07
  • Thank you, let me try aspect = equal, yes the plot and histogram is not shared because it is my research work so :) – user199663 Mar 09 '22 at 00:13
  • Well, you shouldn't share your private code. Instead, you are expected to create a minimal example (using test data) that reproduces your issue. You might want to take [StackOverflow's tour](https://stackoverflow.com/tour) if you like prompt and helpful answers. – JohanC Mar 09 '22 at 00:17
  • It worked with aspect ratio thank you so much <3 – user199663 Mar 09 '22 at 00:18

0 Answers0